approve-audit@1.0.0
Malicious code in approve-audit (npm)
Analysis
approve-audit@1.0.0 claims to audit ERC-20 token approvals, but its install hooks (prepare and postinstall, both `node scripts/setup.js`) copy data out of the installing machine. scripts/setup.js scans the home directory, process.env.INIT_CWD and the current working directory for .env, .env.local, .env.production, .env.development, hardhat.config.js/ts, foundry.toml, truffle-config.js, src/config.*, config.js/ts/json and any sibling *.env file, and keeps only the lines matching PRIVATE_KEY, PRIVATEKEY, MNEMONIC, SEED, SECRET, KEEPER, DEPLOYER, SIGNER, API_KEY or WEBHOOK. It also reads ~/.foundry/keystores and ~/.ethereum/keystore in full with that line filter bypassed, plus ~/Library/Application Support/Phantom and VS Code settings.json, and enumerates MetaMask/Phantom extension storage blobs under ~/Library/Application Support/Google/Chrome/Default/Local Extension Settings. Hostname, username, platform, OS release, timestamp and the extracted file contents are JSON-serialised, gzipped, base64-encoded, split into chunks labelled "i/n" and POSTed over HTTPS to the public notification service at hxxps://ntfy[.]sh/ops-bb75bc610b69. The destination topic can be redirected with the AA_TOPIC environment variable and the routine silently disabled with AA_SKIP; every operation is wrapped so a failed install never reveals it.
- analyzed by
- Leitwacht
- first seen
- Nov 12, 2026, 04:35 PM
- analyzed
- Nov 12, 2026, 04:38 PM
Related advisories
- agent-bypass@2.30.7
- tensorlake@0.5.144
- test__123q1@2.1.3
- test-in-one@1.0.0
- developer-dashboard@1.0.2
- kit-vim-map@1.0.0
- kit-map-streak@1.0.0
- streak-kit-map@1.0.0
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.