MAL-2026-12354

See a problem?
Import Source
https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/code-analyzer-mcp/MAL-2026-12354.json
JSON Data
https://api.osv.dev/v1/vulns/MAL-2026-12354
Published
2026-08-05T12:38:16Z
Modified
2026-08-05T13:34:51.714515690Z
Summary
Malicious code in code-analyzer-mcp (npm)
Details

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

Source: amazon-inspector (41c70b60414be4e045ae4c1eff1ab33b674c78cc9e2eadadfbdca6317de3a251)

index.js contains a top-level IIFE that runs unconditionally when the MCP server is launched (via the package's main/bin entry). The IIFE spawns calc.exe through childprocess.execSync and runs reconnaissance commands (whoami, hostname, ipconfig), writing collected host information (username, hostname, platform, PATH fragments, COMPUTERNAME/USERDOMAIN env vars) to a file in the OS temp directory (trae-mcp-rce-poc.txt). Source comments in the file explicitly label the block as a malicious payload / RCE proof-of-concept. In addition, the server registers an MCP tool named run_command whose handler passes the client-supplied command argument directly to childprocess.execSync with shell: true and a 30s timeout, giving any connected MCP client (including a model reached via prompt injection) unauthenticated arbitrary shell execution on the host under the installer's account. The package presents itself as a code-analysis MCP server, but its actual behavior is host reconnaissance plus a remote shell sink.

Database specific
{
    "malicious-packages-origins": [
        {
            "source": "amazon-inspector",
            "modified_time": "2026-08-05T12:38:16Z",
            "sha256": "41c70b60414be4e045ae4c1eff1ab33b674c78cc9e2eadadfbdca6317de3a251",
            "id": "IN-MAL-2026-014738",
            "versions": [
                "1.0.0"
            ],
            "import_time": "2026-08-05T13:08:42.297635724Z"
        }
    ]
}
References
Credits

Affected packages

npm / code-analyzer-mcp

Package

Affected ranges

Affected versions

1.*
1.0.0

Database specific

cwes
[
    {
        "name": "Embedded Malicious Code",
        "cweId": "CWE-506",
        "description": "The product contains code that appears to be malicious in nature."
    }
]
indicators
{
    "package_integrity": [
        {
            "hashes": {
                "sha512_sri": "sha512-rEqNcOv79PY3Va2XflX17Y39aIngpxCDWRdrgpyyjFZu66eqEyHRpFEcLFc6AyToKGpU9hhjQfUwH0TkYxT9Cw==",
                "sha1": "01e463ec7aed144f390a111fe04782fafe10973f"
            },
            "filename": "code-analyzer-mcp-1.0.0.tgz"
        }
    ],
    "evidence_files": [
        {
            "path": "index.js",
            "sha256": "d4ee4de2b07f63e6d32081646829b1bca00900291d414b6f8939ba4fc53104e7",
            "tlsh": "78e133d90df695748d63a4692a1f3005313ae1176908feb0becc57790f8879886f27e9"
        }
    ]
}
source
"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/code-analyzer-mcp/MAL-2026-12354.json"