chai-as-promised-plus (npm) · Malicious Code
Affects chai-as-promised-plusSource GCVE Database
Malicious package : remove chai-as-promised-plus and rotate any secrets on hosts that installed it.
Data as of 10 Aug 2026, 15:52 UTC
Malicious package
Published to npm · OSV MAL-2026-13703
What to do
Remove chai-as-promised-plus from every project, lockfile and image that pulls it in. Treat any host that installed it as compromised: rotate the credentials, tokens and keys it could read, from a clean machine.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| npmchai-as-promised-plus | Affected
| Fixed in– |
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
Description
The npm package 'chai-as-promised-plus' version 6.1.3 is a typosquatting malicious package that mimics the legitimate 'chai-as-promised' assertion helper. It contains a large obfuscated JavaScript payload that replaces the module exports at load time, executing attacker-controlled code within the consumer's Node.js process. This behavior is characteristic of supply-chain attacks where malicious code is delivered to users who install the package.