MAL-2026-11138

See a problem?
Import Source
https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/json-schema-inspector/MAL-2026-11138.json
JSON Data
https://api.osv.dev/v1/vulns/MAL-2026-11138
Published
2026-07-28T13:41:27Z
Modified
2026-07-28T14:37:01Z
Summary
Malicious code in json-schema-inspector (npm)
Details

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

Source: amazon-inspector (023b104d04c30fccd05f5db5842a2d8735c572eb13cfbb5ca7ba763eeb525429)

The package advertises itself as a JSON/XML schema validator, but both public entry points (validateJson, validateXml in lib/core.js) invoke a trigger() routine that performs remote code execution against the installer's host. The C2 URL is stored as XOR-encoded hex (key 0x55) and decodes to a manifest hosted at https://cdn.jsdelivr.net/gh/cryptonomad411/cool-utils/package.json. The manifest supplies per-platform payload URLs (wurl/lrurl/laurl/mrurl/maurl) selected by process.platform and process.arch. lib/core.js then spawns node -e (Windows) or sh -c (Linux/macOS) at lines 97 and 114 to execute AES-256-CBC-decrypted staging scripts (aesDecrypt with a statically-derived key) that run the fetched payload. Execution is gated by sandbox-evasion checks in isEnvironment() (os.uptime() >= 300s, os.cpus().length >= 2, os.totalmem() >= 2GB) and a one-shot lock file at ~/.cache/..lock (or %APPDATA%.cache..lock) so the dropper runs once per victim. The combined obfuscation of the C2 URL and staging scripts, the sandbox-evasion gating, the per-host persistence marker, and the mismatch between advertised purpose (schema validation) and shipped behavior (attacker-controlled code execution) together confirm hostile intent.

Database specific
{
    "malicious-packages-origins": [
        {
            "id": "IN-MAL-2026-010955",
            "import_time": "2026-07-28T14:20:01.29977296Z",
            "modified_time": "2026-07-28T13:41:27Z",
            "sha256": "023b104d04c30fccd05f5db5842a2d8735c572eb13cfbb5ca7ba763eeb525429",
            "source": "amazon-inspector",
            "versions": [
                "1.1.5"
            ]
        },
        {
            "id": "IN-MAL-2026-010963",
            "import_time": "2026-07-28T14:20:01.625279763Z",
            "modified_time": "2026-07-28T13:42:34Z",
            "sha256": "5ca6605b7321cc0ba97351bc791f17829f467951eaa9de99ce928f1338c4fcd1",
            "source": "amazon-inspector",
            "versions": [
                "1.1.7"
            ]
        },
        {
            "id": "IN-MAL-2026-010959",
            "import_time": "2026-07-28T14:20:01.45017287Z",
            "modified_time": "2026-07-28T13:42:00Z",
            "sha256": "65d8e513622df69653c38f8f1ded6dbf9022d731b6f9549b4eb2338b69cc6781",
            "source": "amazon-inspector",
            "versions": [
                "1.1.6"
            ]
        },
        {
            "id": "IN-MAL-2026-010956",
            "import_time": "2026-07-28T14:20:01.35255909Z",
            "modified_time": "2026-07-28T13:41:37Z",
            "sha256": "6b933581c13815fdf509261acd0f26d8f9446b313d2ff7866c274167e986d87b",
            "source": "amazon-inspector",
            "versions": [
                "1.1.4"
            ]
        }
    ]
}
References
Credits

Affected packages

npm / json-schema-inspector

Package

Name
json-schema-inspector
View open source insights on deps.dev
Purl
pkg:npm/json-schema-inspector

Affected ranges

Affected versions

1.*
1.1.4
1.1.5
1.1.6
1.1.7

Database specific

cwes
[
    {
        "cweId": "CWE-506",
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code"
    },
    {
        "cweId": "CWE-506",
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code"
    },
    {
        "cweId": "CWE-506",
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code"
    },
    {
        "cweId": "CWE-506",
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code"
    }
]
indicators
{
    "evidence_files": [
        {
            "path": "lib/core.js",
            "sha256": "438a89bce1a9a814c17ea1ab4b5f0c536bcf00efab3187b4e29f5ccc270cb4bb",
            "tlsh": "fa12d8d52ee6e5110a7597e647f3c41aef3aa1232605c25dbd8cc6402fb1264c662efc"
        },
        {
            "path": "lib/helpers.js",
            "sha256": "f0c668acb0eaf1606dace2c27b1d6f290d346ac4de368f655cc318da5fa74d96",
            "tlsh": "f131dc802d7274a043b2a6f65a77e80ed4a8663771008398f76e5a865f30c548ad2eec"
        }
    ],
    "package_integrity": [
        {
            "filename": "json-schema-inspector-1.1.5.tgz",
            "hashes": {
                "sha1": "02a0b829eb18c5b712d301734a06abc7a49e90fd",
                "sha512_sri": "sha512-hoI9ZvlE/w0IxRb2F+U+kOFU7OOHIBGEsclVeTS/ewfghWLquQBaEralMGMMtKYqaeXLJ8/17P08Os7glmXLRg=="
            }
        }
    ]
}
source
"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/json-schema-inspector/MAL-2026-11138.json"