chai-as-sets (npm) · Malicious Code
Affects chai-as-setsSource GCVE Database
Malicious package : remove chai-as-sets and rotate any secrets on hosts that installed it.
Data as of 14 Jul 2026, 09:40 UTC
Malicious package
Published to npm · OSV MAL-2026-10519
What to do
Remove chai-as-sets 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-sets | 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-sets version 3.1.3 contains malicious code that executes upon module load. It spawns a detached child process which decodes a hardcoded URL and sends the installer's environment variables to a remote server. The server's response is executed as code with access to the package's require function, enabling arbitrary remote code execution. The package attempts to disguise itself by impersonating another library (pino).