Skip to main content
MalwarePublished Updated

whs4_pnm (npm) · Malicious Code

Affects whs4_pnmSource GCVE Database

0

Malicious package : remove whs4_pnm and rotate any secrets on hosts that installed it.

Data as of 10 Jul 2026, 09:29 UTC

Classification

Malicious package

Published to npm · OSV MAL-2026-6953

What to do

Remove whs4_pnm 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

ProductAffectedFixed in
npmwhs4_pnmAffected–Fixed in–

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

Description

--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (47d72187d8b59a9a40cb8397d064bc7319b20e19ee7d48b870432bd96952b089) The package declares a postinstall script (`node index.js`) that runs unconditionally on `npm install`. The script POSTs the absolute `__filename` path (which contains the installer's OS username via the home-directory prefix), the Node.js version, and the platform/architecture to a hardcoded Discord webhook at `https://discord.com/api/webhooks/1523336123319849031/...`. There is no opt-in, disclosure, or configuration option — every install silently transmits host-identifying data to an author-controlled endpoint. The package's own README and default internal `packageName` value (`whs4_typo`) indicate the package is positioned as a typo-target beacon, matching the typosquat-with-callback pattern where the attacker collects fingerprints of developers who mistype a legitimate package name. ## Source: ghsa-malware (6c7538f81810e9802a2f2a45995000376e76177b2eb21d1c6e8aea63942a330d) Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.

References

Community reviews

Loading reviews…