Malicious code in 1nestjs (npm)
Description
The npm package '1nestjs' version 0.0.1 is a typosquatting malicious package that executes code during installation to exfiltrate environment variables and provide a remote shell to an attacker. It collects environment variables with keys matching sensitive patterns and sends them to a remote server, then opens an interactive shell connection to that server.
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The '1nestjs' package (version 0.0.1) is a typosquatting package targeting users who may mistakenly install it instead of the legitimate 'nestjs' package. During the npm install process, it runs a postinstall script that iterates over environment variables, extracting those with keys matching /^(SECRET|API|TOKEN|KEY)/, and sends this data as JSON over a raw TCP connection to a remote IP address (84.32.22.44) on port 9999. Additionally, it executes a netcat command to open an interactive shell on the attacker's host, allowing remote command execution on the victim's machine. The package metadata self-identifies as a typosquat, indicating intentional malicious behavior.
Potential Impact
This package can lead to the compromise of sensitive environment variables such as secrets, API keys, tokens, and keys by exfiltrating them to an attacker-controlled server. Furthermore, it grants the attacker an interactive shell on the victim's machine, enabling full remote control and potential further compromise of the system where the package is installed.
Mitigation Recommendations
No official patch or fix is available since this is a malicious typosquatting package. The primary mitigation is to avoid installing the '1nestjs' package and verify package names carefully before installation. Use trusted sources and official package names to prevent accidental installation of typosquatting packages. Consider using package integrity verification tools and npm security features to detect and block malicious packages.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-15909
- Osv Schema Version
- 1.7.4
- Ecosystems
- ["npm"]
Threat ID: 6a9ad4ecacd9273b49b677bf
Added to database: 09/04/2026, 14:25:48 UTC
Last enriched: 09/07/2026, 17:29:38 UTC
Last updated: 10/03/2026, 23:41:22 UTC
Views: 24
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.