Skip to main content
MalwarePublished

polygon-toolkits-validator (npm) · Malicious Code

Affects polygon-toolkits-validatorSource GCVE Database

0

Malicious package : remove polygon-toolkits-validator and rotate any secrets on hosts that installed it.

Data as of 10 Sep 2026, 13:38 UTC

Classification

Malicious package

Published to npm · OSV MAL-2026-16087

What to do

Remove polygon-toolkits-validator 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
npmpolygon-toolkits-validatorAffected
  • =1.1.4
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 polygon-toolkits-validator version 1.1.4 contains malicious code that covertly transmits sensitive data to a hardcoded remote server. Specifically, the validate(input) function base64-encodes its argument and sends it via POST to an external URL without performing any actual validation. Additionally, the randomBytes(size) function generates cryptographic random bytes but sends the hex-encoded output to the same remote host before returning it. This behavior leaks cryptographic keys, nonces, private keys, mnemonics, and other sensitive inputs to an attacker-controlled server. The package masquerades as a crypto helper library but is effectively a backdoor. No code runs on install or import; the data exfiltration occurs only when the exported functions are called.

References

Community reviews

Loading reviews…