MAL-2026-15907

See a problem?
Import Source
https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/tiny-folder-tree/MAL-2026-15907.json
JSON Data
https://api.osv.dev/v1/vulns/MAL-2026-15907
Published
2026-09-04T03:45:10Z
Modified
2026-09-04T04:30:06Z
Summary
Malicious code in tiny-folder-tree (npm)
Details

-= Per source details. Do not edit below this line.=-

Source: amazon-inspector (fb7707665659f287294c31f37c4eff9ceba537e9b54859837615929c296a9540)

tiny-folder-tree@0.1.0 declares a postinstall script (src/build.js) that runs on npm install. The script performs a DNS TXT lookup for spreadsheets-documents.com and, when the first character of the first TXT record is '1', invokes src/tools.js which issues an HTTPS request to a URL reconstructed at runtime from obfuscated numeric constants in src/const.js (base-77/base-45 encoded strings decoding to 'https' and an 'HTTPS://...' URL). The response's 'm' header is passed directly to child_process.execSync, yielding arbitrary attacker-controlled shell execution on the installer's machine. The require target for the HTTPS module and the destination URL are both reconstructed via helpers (normalize_hash / normalize_hash_map) to evade static analysis. An author-username bypass ('justin') skips execution on the author's own host, confirming the code is intended to fire on other installers rather than the maintainer.

Database specific
{
    "malicious-packages-origins":  [
        {
            "id":  "IN-MAL-2026-019448",
            "import_time":  "2026-09-04T04:21:20.703137761Z",
            "modified_time":  "2026-09-04T03:45:10Z",
            "sha256":  "fb7707665659f287294c31f37c4eff9ceba537e9b54859837615929c296a9540",
            "source":  "amazon-inspector",
            "versions":  [
                "0.1.0"
            ]
        }
    ]
}
References
Credits

Affected packages

npm / tiny-folder-tree

Package

Name
tiny-folder-tree
View open source insights on deps.dev
Purl
pkg:npm/tiny-folder-tree

Affected ranges

Affected versions

0.*
0.1.0

Database specific

cwes
[
    {
        "cweId":  "CWE-506",
        "description":  "The product contains code that appears to be malicious in nature.",
        "name":  "Embedded Malicious Code"
    }
]
indicators
{
    "evidence_files":  [
        {
            "path":  "src/build.js",
            "sha256":  "264dca0cb6b4b00092f0032d2a5be38f9e0be47440c62c81b21be54aaeb42292",
            "tlsh":  "acf0553ac52a560a03e31b9ca178c85acab2f132238140553b5c6706bff3a601322d2a"
        },
        {
            "path":  "src/const.js",
            "sha256":  "48db2a2dd6cd26cf592013a6d944cf7d23b629b9b957cd1a422661fefee2dacf",
            "tlsh":  "27012ac195dd385316f713e2f2e644c5edfa036552097189bc6885ad0f055d88193ff5"
        }
    ],
    "package_integrity":  [
        {
            "filename":  "tiny-folder-tree-0.1.0.tgz",
            "hashes":  {
                "sha1":  "1e5d8dc052cf6d78d4f4f90df2035f5643c75391",
                "sha512_sri":  "sha512-N9d+LpQzybtTrMrATInSERRJGTwykFKKCTQLTtvoMJglCPXwPkCnCFz9ZWomWvyk0Oheg2Tyuv3RLyRStymymA=="
            }
        }
    ]
}
source
"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/tiny-folder-tree/MAL-2026-15907.json"