MAL-2026-16207

See a problem?
Import Source
https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/chai-as-agile/MAL-2026-16207.json
JSON Data
https://api.osv.dev/v1/vulns/MAL-2026-16207
Published
2026-09-16T06:29:32Z
Modified
2026-09-16T06:45:06Z
Summary
Malicious code in chai-as-agile (npm)
Details

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

Source: amazon-inspector (90d46bc75e0c086e929855baefd9f9f847ebe6e85f8a004c9de72502d0fb6263)

On require('chai-as-agile'), index.js loads lib/initializeCaller.js which decodes a base64-obfuscated URL to https://ipcheck-hashed.vercel.app/api/auth/6c1d60d35852ef0c05df and POSTs the full contents of process.env to that endpoint with an 'x-secret-header' header. It then passes the HTTP response body to new Function('require', response.data) and invokes it with require, granting the endpoint operator arbitrary code execution in the consumer's Node process on every import. Any credentials present in the environment (AWS_*, GITHUB_TOKEN, NPM_TOKEN, CI secrets) are transmitted verbatim to the attacker. The package name resembles the popular 'chai' assertion library, consistent with a typosquat lure.

Database specific
{
    "malicious-packages-origins": [
        {
            "id": "IN-MAL-2026-020079",
            "import_time": "2026-09-16T06:31:14.820646873Z",
            "modified_time": "2026-09-16T06:29:32Z",
            "sha256": "90d46bc75e0c086e929855baefd9f9f847ebe6e85f8a004c9de72502d0fb6263",
            "source": "amazon-inspector",
            "versions": [
                "2.4.7"
            ]
        }
    ]
}
References
Credits

Affected packages

npm / chai-as-agile

Package

Name
chai-as-agile
View open source insights on deps.dev
Purl
pkg:npm/chai-as-agile

Affected ranges

Affected versions

2.*
2.4.7

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": "lib/initializeCaller.js",
            "sha256": "6ae47651f95735e18c7370aa04d1577ffbd19c20eed57729c777cac6d4a83f4b",
            "tlsh": "9bf08b5d28ba203942ae64e2bf1b14561453f82232d5d865f7cc836a0f8dd4daaa36d8"
        }
    ],
    "package_integrity": [
        {
            "filename": "chai-as-agile-2.4.7.tgz",
            "hashes": {
                "sha1": "f230d49463fe3972e560d79547ef8f6c02fe32aa",
                "sha512_sri": "sha512-HZz2KMXBvduvXCP5uL89qCdoOQggDAE/QVO0xlu9KcHZz2Dk/TGp6C3sjgMQq3J7GL1ytngrP5D0IRKmk+gpzg=="
            }
        }
    ]
}
source
"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/chai-as-agile/MAL-2026-16207.json"