express-initial@12.1.7
Malicious code in express-initial (npm)
Analysis
Package express-initial@12.1.7 is a combosquat of the popular express framework. The postinstall hook runs a heavily obfuscated index.js (javascript-obfuscator style, RC4-like string decryption, opaque numeric constants). The code loads child_process, fs, and path modules, constructs a URL from decoded strings, fetches a payload from a remote host, writes it to disk via writeFileSync, and then spawns the downloaded file via child_process.spawn with windowsHide:true — a classic second-stage dropper pattern. The README claims to be a "safe wrapper module" with security notes advising sandboxing, but the package name express-initial does not match the README's module name, and the hidden download-and-spawn behaviour makes this an active supply-chain attack, not research.
- analyzed by
- Leitwacht
- first seen
- Jun 11, 2026, 01:36 PM
- analyzed
- Jun 11, 2026, 01:38 PM
Related advisories
- node-gyp-runtime@1.0.0
- mjs-biginteger@5.0.6
- vite-config-optimizer@1.1.4
- @zervonex/baileys@4.0.9
- @izi-coder/baileys@2.0.5
- @zervonex/baileys@4.0.6-final
- @rizzkezik/baileys@1.1.1
- @jiancodes/baileys@2.0.5
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.