Skip to main content

Malicious code in mnemonic-to-key (npm)

0
Critical
Published: 08/05/2026 (08/05/2026, 15:39:21 UTC)
Source: GCVE Database
Product: mnemonic-to-key

Description

The npm package 'mnemonic-to-key' version 1.2.0 contains malicious code that exfiltrates environment variables and system information to a Telegram bot on first import. It acts as a typosquat for the legitimate 'bip39' package, targeting cryptocurrency developers by capturing sensitive data such as API tokens and cloud credentials from process environments. The package sends this data encoded via HTTPS GET requests and suppresses repeated transmissions using a flag file.

Affected software

npmghsa
mnemonic-to-key
Affected versions
=1.2.0

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

AILast updated: 08/05/2026, 23:00:49 UTC

Technical Analysis

The 'mnemonic-to-key' npm package version 1.2.0 includes malicious code that, upon being required, serializes the entire process.env along with hostname, username, homedir, platform, and current working directory into a JSON object. This data is base64-encoded and sent via an HTTPS GET request to a Telegram bot endpoint using a hardcoded bot token and chat ID. The package masquerades as a drop-in replacement for the legitimate 'bip39' package, lazily re-exporting the real module if present, or otherwise providing stub functions. This behavior indicates a typosquatting attack aimed at exfiltrating sensitive environment variables commonly found in developer and CI environments, such as API tokens and cloud credentials. A flag file in the OS temporary directory prevents repeated data exfiltration on subsequent imports.

Potential Impact

Sensitive environment variables and system information are exfiltrated to an attacker-controlled Telegram bot on first import of the malicious package. This can lead to credential leakage including API tokens, cloud service credentials, and publish tokens, potentially compromising developer and CI environments. The attack targets cryptocurrency developers by impersonating a commonly used package, increasing the risk of inadvertent installation and data theft.

Defensive Guidance

No official patch or fix is currently documented. Users should avoid using the 'mnemonic-to-key' package version 1.2.0 and verify the authenticity of packages before installation, especially those related to cryptocurrency. Remove the malicious package if installed and rotate any potentially exposed credentials. Monitor for typosquatting packages and use trusted package sources. Patch status is not yet confirmed — check the vendor advisory or trusted security sources for updates.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
MAL-2026-13349
Osv Schema Version
1.7.4
Ecosystems
["npm"]

Threat ID: 6a738520bf8831d5394ef8f6

Added to database: 08/05/2026, 18:46:56 UTC

Last enriched: 08/05/2026, 23:00:49 UTC

Last updated: 09/07/2026, 22:24:16 UTC

Views: 18

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

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

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses