{"id":"MAL-2026-10640","revision":"a2c4dd394b8e4c7d9193697637d18fe3","records":[{"revision":"a2c4dd394b8e4c7d9193697637d18fe3","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"MAL-2026-10640","aliases":[],"title":"Malicious code in polygon-toolkit-validation (npm)","description":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (58c3f2f27ce890479049767726c06bf083f96fe5c9916f43f5345f62ed9671c1)\nThe package exposes `validate(t)` and `randomBytes(t,e)` which route their arguments through an internal `check_validator` that base64-encodes the value and unconditionally POSTs it to the hardcoded endpoint `https://validator.polymarket.shop/v2` (body shape `{action:\"validator\",content:btoa(t)}`). `randomBytes(t,e)` first calls `crypto.randomBytes(t).toString('hex')` and then ships the generated hex bytes to the same endpoint, so any consumer using this API to derive cryptographic keys, IVs, or seeds transmits that secret material off-host. The destination is not caller-configurable and is not the package's documented purpose. The package is named `polygon-toolkit-validation` but the tarball is `web3-validator-1.0.9.tgz` and the declared repository is `serhiidemianov/validate-solana`; the module shadows Node crypto function names (`createCipheriv`, `createDecipheriv`, `createPrivateKey`, `randomBytes`, `scrypt`) and impersonates the legitimate `web3-validator` package. The `polymarket.shop` host typosquats Polymarket and is attacker-controlled.\n","state":0,"publishedAt":"2026-07-15T03:41:24+00:00","modifiedAt":"2026-07-15T05:20:10.8435108+00:00","affected":[{"ecosystem":"npm","name":"polygon-toolkit-validation","ranges":[],"versions":["1.0.9","1.1.0"],"rawVersionEvidence":null}],"metrics":[],"references":["https://www.npmjs.com/package/polygon-toolkit-validation/v/1.0.9","https://www.npmjs.com/package/polygon-toolkit-validation/v/1.1.0"],"sourceUrl":"https://osv.dev/vulnerability/MAL-2026-10640","license":"OSV · upstream source license applies","key":"osv:MAL-2026-10640","identifiers":["MAL-2026-10640"]},"retained":false,"historicalAffected":[]}],"coverage":[]}