Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-39973-PoC — Proof of concept (builder) for CVE-2026-39973 (apktool) | Kitploit
Tools/GitHubGitHub/frawlaboy/cve-2026-39973-poc
Vulnerability AnalysisExploitationWeb Application ExploitationPapers & ResearchLearning & Education
GitHubfrawlaboy/cve-2026-39973-poc

CVE-2026-39973-PoC

Proof of concept (builder) for CVE-2026-39973 (apktool)

View Repository
3296 months agoNot yet reviewed
Share

CVE-2026-39973-PoC

This is a small C# apk file builder for CVE-2026-39973.

Credits

  • OnlyToxi - Helping with the path (will be helping further) & emotional support.
  • iBotPeaches/Apktool - Documentation & parsing.

Disclaimer

  • This is a proof of concept, which is made for educational purposes only!
  • AI has NOT been used (except for small questions about serialization) while writing this code or this documentation.
  • My knowledge is LIMITED. This is my first CVE PoC. The documentation may be wrong or incomplete.
  • The code may be difficult to read since I was in a hurry and sleep deprived (sorry).

CVE-2026-39973

CVE-2026-39973 is a path traversal vulnerability within the github repo iBotPeaches/Apktool affecting version 3.0.1.

It allows attackers to create their own resources and inject a ..\ sequence within an entry's type, allowing a threat actor to write any file to ~/.bashrc or the Windows startup path.

Security regression

This vulnerability comes from a security regression in commit e10a045 (PR #4041) which removes BrutIO.detectPossibleDirectoryTraversal() from ResFileDecoder.java

ResFileDecoder.java#L103-L109 BEFORE:

String outResPath = entry.getTypeName() + entry.getConfig().getQualifiers() + "/" + entry.getName();
if (BrutIO.detectPossibleDirectoryTraversal(outResPath)) {
    LOGGER.warning("Potentially malicious file path: " + outResPath + ", using instead: " + inResPath);
    outResPath = inResPath;
} else if (!ext.isEmpty()) {
    outResPath += "." + ext;
}

ResFileDecoder.java#L103-L104 AFTER:

String outResPath = entry.getTypeName() + entry.getConfig().getQualifiers() + "/" + entry.getName()
    + (ext.isEmpty() ? "" : "." + ext);

This commit removed a judged "useless" check on the whole output path as entry.name was already checked beforehand (ResEntrySpec constructor).

The author forgot that the entry's Type name could be subject to a path traversal by crafting our own malicious resources.arsc.

Resources.arsc

resources.arsc is a file containing the resource data, paths, type names and more. It stores all we need to be able to modify the type name or craft a resource.arsc file to exploit Apktool. Despice its reccurence, i've only found poor but satisfying documentation on the serialization.

At this point, it is strongly reccomended to read apktool's documentation).

I started basing myself off Apktool directly as I'm gonna need to build a resources.arsc file for this application exclusively.

I downloaded a random APK file off of the internet and opened it with 7zip. Then I extracted the resources.arsc file and started studying the data structures along with Apktool's parser code. Then I made a small C# builder for the resources.arsc file, writing a ResTable and a ResPackage with one ResType which has the ..\ sequence and the path of Windows Startup folder, it also has one entry which is the payload file.

Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    851
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    538
  • 3

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    420
  • 4

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    357
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    297
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    280

Explore all tools

Browse our collection of tools

View all tools →