janus-ftnpm
Malicious code in janus-ft (npm) Remove it immediately and rotate any exposed credentials.
What this malware does
On npm install, the package's postinstall.js script harvests installer-side secrets and ships them to a hardcoded bare-IP C2 endpoint. Specifically, it (1) collects hostname, username, and cwd; (2) iterates process.env and selects keys matching the regex /KEY|SECRET|TOKEN|PRIVATE|MNEMONIC|PASSWORD|RPC|ALCHEMY|INFURA|DATABASE|WALLET/i; (3) reads.env from cwd, parent directories, and the user's home directory; (4) reads ~/.npmrc (leaking npm auth tokens that enable further supply-chain compromise) and ~/.config/ipor-fusion/config.json (targeting users of the IPOR Fusion DeFi protocol); and (5) POSTs the bundled payload to https://193.203.169.109:8443/c/janus-ft with TLS verification disabled (rejectUnauthorized:false). The package's main entry (index.js) is module.exports = {}; — it provides no actual functionality, confirming the package exists solely to execute the credential-harvesting payload at install time. The targeted read of ipor-fusion config plus the blockchain-developer-oriented env keyword list (MNEMONIC, PRIVATE, WALLET, ALCHEMY, INFURA) indicate this is a targeted attack on DeFi/blockchain developers.
Malicious versions
Indicators of compromise (SHA-256)
Frequently asked questions
Campaign
References
Credits
- Amazon Inspector · finder
Scan your dependencies
O3 Security blocks malicious packages like this at install time and in CI.
Supply-chain protection