Malicious code in @public-for-cdao/token (npm)
Description
The @public-for-cdao/token npm package version 99.99.99 is a malicious dependency-confusion payload that executes a postinstall script to steal sensitive credentials. The embedded recon.js script collects a wide range of secrets including CI tokens, cloud credentials, private keys, and environment variables from the host system and sends them to attacker-controlled endpoints. This package attempts to impersonate an internal package to trick users into installing it.
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 @public-for-cdao/token package version 99.99.99 contains a postinstall hook that runs a recon.js script during npm installation. This script collects host identity information and enumerates environment variables and files for sensitive credentials such as AWS keys, GitLab tokens, SSH keys, database passwords, private keys, cryptocurrency mnemonics, and tokens for Docker, npm, Slack, and Discord. It also searches common CI/CD runner directories and .env files for secrets. The collected data is exfiltrated via HTTPS POST requests to two attacker-controlled endpoints with TLS verification disabled. The package name and version suggest it is a dependency confusion attack targeting an internal @cdao/token package.
Potential Impact
Successful installation of this malicious package results in theft of a broad range of sensitive credentials and secrets from the host environment, potentially leading to unauthorized access to cloud services, source code repositories, deployment environments, databases, and communication platforms. This can facilitate further compromise of the victim's infrastructure and data.
Defensive Guidance
Avoid installing packages from untrusted or unknown public scopes that mimic internal package names. Verify package provenance before installation, especially for packages with suspiciously high version numbers or unknown authorship. Remove the @public-for-cdao/[email protected] package if installed. There is no official patch or fix since this is a malicious package rather than a vulnerability in legitimate software. Use strict package source controls and consider using tools that detect dependency confusion attacks.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-10603
- Osv Schema Version
- 1.7.4
- Aliases
- ["GHSA-cvjj-96jr-345h"]
- Ecosystems
- ["npm"]
Threat ID: 6a96f31bacd9273b49e4995b
Added to database: 09/01/2026, 15:45:31 UTC
Last enriched: 09/08/2026, 06:23:47 UTC
Last updated: 10/04/2026, 06:09:47 UTC
Views: 25
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.