Malicious code in @zzzcrypto/bitcoin-lib (npm)
The npm package @zzzcrypto/bitcoin-lib version 6.1.7 contains malicious code that exfiltrates environment variables and host information to a remote Telegram endpoint. It masquerades as a drop-in replacement for bitcoinjs-lib, proxying calls to the legitimate library if present to avoid detection. The exfiltrated data includes sensitive environment variables that may contain credentials, API tokens, and cloud keys, leading to credential and host-identity theft.
AI Analysis
Technical Summary
The @zzzcrypto/bitcoin-lib npm package (version 6.1.7) includes code that, upon being required, serializes process environment variables along with host details such as hostname, username, home directory, platform, current working directory, and a timestamp. This data is base64-encoded and sent via an HTTPS GET request to api.telegram.org using a hardcoded bot token and chat_id. A temporary flag file limits repeated exfiltration to reduce noise. The package attempts to require the legitimate bitcoinjs-lib to proxy its API, maintaining normal behavior for callers and evading suspicion. Internal identifiers in the exfiltration code are obfuscated. Because environment variables in development and CI environments often contain sensitive credentials, this behavior constitutes credential and host-identity theft for any process importing this package.
Potential Impact
Any process importing @zzzcrypto/bitcoin-lib version 6.1.7 risks leaking sensitive environment variables and host identity information to an attacker-controlled Telegram endpoint. This can lead to compromise of credentials, API tokens, cloud keys, and other secrets stored in environment variables, potentially enabling further unauthorized access or lateral movement within affected environments.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately remove and avoid using the @zzzcrypto/bitcoin-lib package version 6.1.7. Verify all dependencies for malicious packages and replace them with trusted alternatives, such as the legitimate bitcoinjs-lib. Monitor for any signs of credential misuse or unauthorized access resulting from this exfiltration. Patch status is not yet confirmed — check the vendor advisory or trusted security sources for updates.
Malicious code in @zzzcrypto/bitcoin-lib (npm)
Description
The npm package @zzzcrypto/bitcoin-lib version 6.1.7 contains malicious code that exfiltrates environment variables and host information to a remote Telegram endpoint. It masquerades as a drop-in replacement for bitcoinjs-lib, proxying calls to the legitimate library if present to avoid detection. The exfiltrated data includes sensitive environment variables that may contain credentials, API tokens, and cloud keys, leading to credential and host-identity theft.
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 @zzzcrypto/bitcoin-lib npm package (version 6.1.7) includes code that, upon being required, serializes process environment variables along with host details such as hostname, username, home directory, platform, current working directory, and a timestamp. This data is base64-encoded and sent via an HTTPS GET request to api.telegram.org using a hardcoded bot token and chat_id. A temporary flag file limits repeated exfiltration to reduce noise. The package attempts to require the legitimate bitcoinjs-lib to proxy its API, maintaining normal behavior for callers and evading suspicion. Internal identifiers in the exfiltration code are obfuscated. Because environment variables in development and CI environments often contain sensitive credentials, this behavior constitutes credential and host-identity theft for any process importing this package.
Potential Impact
Any process importing @zzzcrypto/bitcoin-lib version 6.1.7 risks leaking sensitive environment variables and host identity information to an attacker-controlled Telegram endpoint. This can lead to compromise of credentials, API tokens, cloud keys, and other secrets stored in environment variables, potentially enabling further unauthorized access or lateral movement within affected environments.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately remove and avoid using the @zzzcrypto/bitcoin-lib package version 6.1.7. Verify all dependencies for malicious packages and replace them with trusted alternatives, such as the legitimate bitcoinjs-lib. Monitor for any signs of credential misuse or unauthorized access resulting from this exfiltration. Patch status is not yet confirmed — check the vendor advisory or trusted security sources for updates.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-13211
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a73852bbf8831d5394f03ea
Added to database: 08/05/2026, 18:47:07 UTC
Last enriched: 08/05/2026, 22:03:34 UTC
Last updated: 08/05/2026, 22:03:34 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.
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.