# npm maintainer phishing led to malicious releases of chalk, debug, DuckDB and other packages

Source: https://botpassword.com/incidents/2025-09-npm-chalk-debug-hijack
Disclosed: 2025-09-08 · Type: Supply chain · Status: Resolved · Updated: 2026-10-25

On 8 September 2025 phishing emails from the lookalike domain `npmjs.help` captured npm maintainers' passwords and two-factor codes, and the attackers used the accounts to publish malicious versions of 18 widely used packages, including `chalk` 5.6.1 and `debug` 4.4.2, and later four DuckDB packages. The payload rewrote cryptocurrency wallet addresses in browsers; it did not steal developer secrets. Maintainers who entered credentials on a lookalike npm site should reset their password, 2FA and tokens; users should reinstall clean versions and rebuild browser bundles.

Identifiers: CVE-2025-59144, CVE-2025-59037, GHSA-2v46-p5h4-248w, GHSA-4x49-vf9v-38px, GHSA-w62p-hx95-gf2c

## What was exposed

The maintainers' npm credentials: passwords and two-factor codes typed into a pixel-perfect copy of npmjs.com, which forwarded them to the real site so the attacker could change 2FA and create a publishing token. For people who installed the packages, the advisories describe a browser-side payload that hooked `fetch`, `XMLHttpRequest` and wallet APIs to swap cryptocurrency recipient addresses. The `debug` advisory says local, server and command-line environments were not affected, and no source reports theft of developer tokens or environment variables by this payload.

## Who is affected

**Maintainers:** you are affected if you followed a link in an email from an `npmjs.help` address (or any non-npmjs.com domain) and signed in. **Users:** check lockfiles for `chalk` 5.6.1, `debug` 4.4.2, `ansi-styles` 6.2.2, `strip-ansi` 7.1.1, `supports-color` 10.2.1, `ansi-regex` 6.2.1, `wrap-ansi` 9.0.1, `color-convert` 3.1.1, `color-name` 2.0.1, `color-string` 2.1.1, `slice-ansi` 7.1.1, `is-arrayish` 0.3.3, `error-ex` 1.3.3, `simple-swizzle` 0.2.3, `has-ansi` 6.0.1, `supports-hyperlinks` 4.1.1, `chalk-template` 1.1.1, `backslash` 0.2.1, or DuckDB's `duckdb` 1.3.3, `@duckdb/node-api` 1.3.3, `@duckdb/node-bindings` 1.3.3 and `@duckdb/duckdb-wasm` 1.29.2. Installs on 8 September 2025 are the risk window; the risk is to web apps that shipped a browser bundle built with one of those versions.

## What to do

1. If you entered npm credentials on a lookalike site: reset your npm password, re-enroll 2FA, revoke every npm access token, and review recent publishes on your packages.
2. Search lockfiles for the versions listed above, delete `node_modules`, clear the package-manager cache and reinstall clean versions (for `debug`, 4.4.3 or later).
3. Rebuild and redeploy any browser bundle built while an affected version was installed.
4. Purge the affected versions from private registry mirrors and caches.
5. Prefer phishing-resistant 2FA (a security key or passkey) for registry accounts, since a one-time code can be relayed by a proxy site.

## Keys to rotate

- [npm](https://botpassword.com/keys/npm)

## Timeline

- 2025-09-05: The phishing domain `npmjs.help` is registered, according to Aikido. ([source](https://www.aikido.dev/blog/npm-debug-and-chalk-packages-compromised))
- 2025-09-08: From 13:16 UTC Aikido's feed flags malicious releases of `debug`, `chalk` and 16 related packages published from the maintainer's account. ([source](https://www.aikido.dev/blog/npm-debug-and-chalk-packages-compromised))
- 2025-09-08: GitHub publishes advisory GHSA-2v46-p5h4-248w for `chalk` 5.6.1 as malware. ([source](https://github.com/advisories/GHSA-2v46-p5h4-248w))
- 2025-09-09: DuckDB discloses that a maintainer entered the `duckdb_admin` credentials and 2FA on the same phishing site, after which the attacker created an API token and published malicious DuckDB versions. DuckDB rotated passwords, tokens and keys. ([source](https://github.com/duckdb/duckdb-node/security/advisories/GHSA-w62p-hx95-gf2c))
- 2025-09-15: Advisory GHSA-4x49-vf9v-38px (CVE-2025-59144) is published for `debug` 4.4.2, with 4.4.3 as the fixed release. ([source](https://github.com/advisories/GHSA-4x49-vf9v-38px))

## Indicators

- Phishing sender domain `npmjs.help`, registered 2025-09-05 according to Aikido.
- Malicious versions: `chalk` 5.6.1, `debug` 4.4.2, `ansi-styles` 6.2.2, `strip-ansi` 7.1.1, `supports-color` 10.2.1 and the others listed above.
- Malicious DuckDB versions: `duckdb`, `@duckdb/node-api` and `@duckdb/node-bindings` 1.3.3, `@duckdb/duckdb-wasm` 1.29.2.

## Sources

- https://www.aikido.dev/blog/npm-debug-and-chalk-packages-compromised
- https://github.com/advisories/GHSA-2v46-p5h4-248w
- https://github.com/advisories/GHSA-4x49-vf9v-38px
- https://github.com/duckdb/duckdb-node/security/advisories/GHSA-w62p-hx95-gf2c
