commonjs-assert (npm) · Malicious Code
Affects commonjs-assertSource GCVE Database
Malicious package : remove commonjs-assert and rotate any secrets on hosts that installed it.
Data as of 26 Oct 2026, 15:56 UTC
Malicious package
Published to npm · OSV MAL-2026-10676
What to do
Remove commonjs-assert 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 |
|---|---|---|
| npmcommonjs-assert | 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 'commonjs-assert' version 1.0.3 is a malicious package that impersonates Node.js's built-in 'assert' module. When required, it spawns a detached Node.js child process that fetches and executes remote code via an obfuscated payload, resulting in arbitrary remote code execution on the host system.