Skip to content
~/drains.watch_
Soon
PastCritical✓ContainedAI · AI malware

Compromised Nx npm packages ran victims' AI command-line tools to hunt for wallet and keystore files

Nx build system on npm

Around 26 August 2025 malicious versions of Nx, a widely used JavaScript build tool, were published to npm and stole GitHub and npm tokens on install. The malware also looked for installed AI command-line tools (Claude, Gemini and Amazon Q) and ran them to search the disk for crypto wallet and keystore files, .env files and SSH keys, then published the results to repos in the victim's own GitHub account. Wiz counted over 1,700 users with leaked secrets and over 6,700 private repos made public, but saw no successful crypto theft, partly because the AI tools often refused. Anyone who installed the bad versions should rotate tokens and move funds from wallet files on that machine.

Why this severity: 1,700 victims.

AI involvement

AI-built malware. The malware ran locally installed AI CLIs (Claude, Gemini, Amazon Q) to inventory wallet, keystore and secret files for theft; Wiz found the AI step worked in under a quarter of cases and saw no successful crypto exfiltration.

Check that a package, extension or app is the real one before installing it, even when an AI assistant suggested it.

Started
Aug 26, 2025
Closed
Sep 6, 2025
Victims
1,700

Follow this incident

At risk

  • Nx build system on npm
  • Multiple EVM chains wallets

What to do now

  • Make any s1ngularity repos private or delete them, then rotate GitHub, npm, cloud and AI API tokens.
  • From a clean device, move funds from any wallet whose keystore, seed or key file was on that machine.
  • Upgrade to a clean Nx version.

Stay safe

Am I affected?

You may be affected if you or your CI installed Nx 20.9.0, 20.11.0, 20.12.0, 21.5.0, 21.6.0, 21.7.0 or 21.8.0 in late August 2025. A new repo named like 's1ngularity-repository' in your GitHub account means the malware ran.

What to do now

  • Make any s1ngularity repos private or delete them, then rotate GitHub, npm, cloud and AI API tokens.
  • From a clean device, move funds from any wallet whose keystore, seed or key file was on that machine.
  • Upgrade to a clean Nx version.

How to avoid this

  • Don't keep wallet files or seed phrases on developer machines; use hardware wallets.
  • Pin dependency versions and avoid installing brand-new releases straight into CI.
  • Don't leave AI CLIs able to run without permission prompts, and keep them away from folders that hold secrets.

Timeline 4

  1. BleepingComputer reported Wiz's tally of 2,180 exposed accounts and 7,200 repositories across three phases.

    Source
  2. Wiz published its analysis: over 1,700 users had secrets leaked, over 6,700 private repos were exposed, and no successful crypto exfiltration had been seen.

    Source
  3. Malicious Nx versions with a data-stealing postinstall script were published to npm.

    Source
  4. News broke that malicious Nx versions on npm were stealing tokens and using local AI CLIs to search for wallet and secret files.

    Source
News & write-ups ›2

How this method works

A popular code package or app update is hijacked to steal wallet keys or swap addresses, hitting everyone who installs it. Read about supply-chain stealers →

Follow new drains and updates in your feed reader or Telegram RSS bot.

Brief for your AI


Get notified about new drains

Follow every new drain and update in your feed reader, Slack, Discord or Telegram RSS bot:

Only follow a chain or a method you care about: every tag has its own feed at /t/<tag>/feed.xml.

Copied