MAL-2026-6698: Malicious code in cursed-modules (npm)
The 'cursed-modules' npm package versions 2.0.0 and 999.0.0 through 999.0.3 contain malicious code designed to steal credentials and sensitive environment data. The package uses lifecycle hooks to execute install-time scripts that collect SSH keys, npm configuration, git history, environment variables, and AWS credentials, exfiltrating them to attacker-controlled endpoints. The malicious payload activates only inside containerized CI/CD environments, evading detection on typical developer machines. This is a dependency confusion attack targeting internal package names to harvest private registry credentials and enable further attacks.
AI Analysis
Technical Summary
The 'cursed-modules' npm package (versions 2.0.0 and 999.0.0 to 999.0.3) is a malicious package that performs credential theft through install-time and require-time scripts. It collects sensitive files such as SSH private keys, npm and git configuration files, environment variables, and AWS credentials by querying the AWS instance metadata service and AWS Secrets Manager. The stolen data is exfiltrated via HTTP PUT requests to hardcoded attacker IP addresses. Execution is gated to trigger only when the hostname matches a Docker container ID pattern, targeting containerized CI/CD environments and avoiding detection in other environments. The package also attempts to harvest private npm registry credentials by reading Verdaccio configuration and htpasswd files. This package is part of a dependency confusion attack designed to shadow internal package names on the public npm registry and facilitate follow-on attacks.
Potential Impact
Successful installation or inclusion of this package in a containerized CI/CD environment results in theft of sensitive credentials including SSH keys, npm and git configuration, environment variables, and AWS credentials. This can lead to unauthorized access to internal systems, private registries, and cloud resources. The attack is stealthy, activating only in container environments, which increases the risk of undetected compromise in automated build and deployment pipelines.
Mitigation Recommendations
No official patch or remediation is currently documented. Patch status is not yet confirmed — check the vendor advisory or trusted security sources for current remediation guidance. Until then, avoid using the 'cursed-modules' package, especially versions 2.0.0 and 999.0.0 through 999.0.3. Implement strict controls on package sources and verify package authenticity to prevent dependency confusion attacks. Monitor for and remove any instances of this package in your environments.
MAL-2026-6698: Malicious code in cursed-modules (npm)
Description
The 'cursed-modules' npm package versions 2.0.0 and 999.0.0 through 999.0.3 contain malicious code designed to steal credentials and sensitive environment data. The package uses lifecycle hooks to execute install-time scripts that collect SSH keys, npm configuration, git history, environment variables, and AWS credentials, exfiltrating them to attacker-controlled endpoints. The malicious payload activates only inside containerized CI/CD environments, evading detection on typical developer machines. This is a dependency confusion attack targeting internal package names to harvest private registry credentials and enable further attacks.
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 'cursed-modules' npm package (versions 2.0.0 and 999.0.0 to 999.0.3) is a malicious package that performs credential theft through install-time and require-time scripts. It collects sensitive files such as SSH private keys, npm and git configuration files, environment variables, and AWS credentials by querying the AWS instance metadata service and AWS Secrets Manager. The stolen data is exfiltrated via HTTP PUT requests to hardcoded attacker IP addresses. Execution is gated to trigger only when the hostname matches a Docker container ID pattern, targeting containerized CI/CD environments and avoiding detection in other environments. The package also attempts to harvest private npm registry credentials by reading Verdaccio configuration and htpasswd files. This package is part of a dependency confusion attack designed to shadow internal package names on the public npm registry and facilitate follow-on attacks.
Potential Impact
Successful installation or inclusion of this package in a containerized CI/CD environment results in theft of sensitive credentials including SSH keys, npm and git configuration, environment variables, and AWS credentials. This can lead to unauthorized access to internal systems, private registries, and cloud resources. The attack is stealthy, activating only in container environments, which increases the risk of undetected compromise in automated build and deployment pipelines.
Mitigation Recommendations
No official patch or remediation is currently documented. Patch status is not yet confirmed — check the vendor advisory or trusted security sources for current remediation guidance. Until then, avoid using the 'cursed-modules' package, especially versions 2.0.0 and 999.0.0 through 999.0.3. Implement strict controls on package sources and verify package authenticity to prevent dependency confusion attacks. Monitor for and remove any instances of this package in your environments.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-6698
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a4452d127e9c797198dfbec
Added to database: 06/30/2026, 23:35:45 UTC
Last enriched: 06/30/2026, 23:39:45 UTC
Last updated: 06/30/2026, 23:39:45 UTC
Views: 2
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.
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.