Skip to content
supplychainattack.orgSupply chain attack incident catalog
containedcritical

Malicious code in add-two-numbers-x7q9m (npm)

The npm package add-two-numbers-x7q9m contained malicious code in its preinstall lifecycle script that harvested npm authentication tokens from the installer's Desktop directory and exfiltrated them to a remote webhook endpoint. The package was disguised as a trivial arithmetic utility but performed credential theft on installation.

ShareXLinkedInHacker News
Disclosed
Last updated
Blast radius
Any developer who installed add-two-numbers-x7q9m via npm install; npm authentication tokens harvested from Desktop .txt files could enable account takeover and downstream supply-chain attacks.
Ecosystems
Attack vectors
Affected entities
  • add-two-numbers-x7q9mnpm package with malicious preinstall script

The npm package add-two-numbers-x7q9m was published with malicious intent. Despite advertising itself as a simple utility to add two numbers, the package's preinstall lifecycle script executed unauthorized reconnaissance and credential harvesting on installation.\n\nThe malicious script enumerated the installer's Desktop directory, searched for .txt files, and used regex pattern matching (/npm_[A-Za-z0-9_-]+/) to extract npm authentication tokens. Any tokens found were transmitted as query parameters to the hardcoded endpoint https://lively-bird-15.webhook.cool.\n\nThis behavior ran automatically during npm install, without user awareness or consent. The harvested npm tokens could be used to compromise the victim's npm registry account and enable downstream supply-chain attacks via the victim's publish rights. The random name suffix (x7q9m) is consistent with a disposable malicious-publish account.\n\nThe incident was identified and credited to the OpenSSF malicious-packages project.

Indicators of compromise

Packages
  • add-two-numbers-x7q9m
Domains
  • lively-bird-15.webhook.cool

Remediation

  • Immediately uninstall add-two-numbers-x7q9m from all systems where it was installed
  • Rotate all npm authentication tokens, especially those that may have been stored in Desktop .txt files
  • Review npm account activity and publish history for unauthorized changes
  • Audit any packages published using the compromised npm account for malicious modifications
  • Check npm audit logs and CI/CD logs for suspicious activity during the window when the package was installed
  • Consider using npm token scoping and IP restrictions to limit token exposure in future

Sources

  1. GitHub Advisory GHSA-9pf9-rmxg-xw8w · GitHub Advisory Database

Cite this entry

"Malicious code in add-two-numbers-x7q9m (npm)." supplychainattack.org, Supply Chain Attack Incident Catalog. Disclosed August 5, 2026; last updated August 5, 2026. https://supplychainattack.org/incident/malicious-code-in-add-two-numbers-x7q9m-npm-c22lr9

Suggest a correction

Found an error or have a newer source? Corrections to factual errors take priority over new entries.

  1. containedcritical

    Malicious code in checkout-desktop-total (npm)

    The npm package checkout-desktop-total contained malicious code that executes a hidden loader on import, downloading and running platform-specific native payloads from attacker-controlled Cloudflare Workers hosts or reconstructing them via DNS TXT records under wel1.ru. Any system that imported this package should be considered compromised.

    npmCompromised package
  2. resolvedcritical

    Malware in @zynkit/jwtbytes

    Malware was discovered in the npm package @zynkit/jwtbytes, resulting in full system compromise for any computer with the package installed or running. All secrets and keys on affected systems should be rotated immediately from a different computer.

    npmCompromised package
  3. containedcritical

    Malware in async-mutex-v2

    Malware was discovered in the npm package async-mutex-v2. Systems with this package installed are considered fully compromised and require immediate remediation including credential rotation and package removal.

    npmCompromised package
  4. containedcritical

    Malware in @junofficial/baileys

    The npm package @junofficial/baileys contained malware that fully compromised any system with the package installed or running. The malicious package has been identified and removed from distribution.

    npmCompromised package