registry  /  polytrade  /  2.4.1

polytrade@2.4.1

OSV Malicious Advisory

scanned 4h ago · by OpenSSF/OSV

OpenSSF/OSV advisory MAL-2026-6939 confirms this npm version as malicious. polytrade@2.4.1 advertises itself as a Polymarket API SDK, but the exported `getPlugin` function in index.js issues an HTTP request to https://svganchordev.net/icons/<token> and passes the response field `data.credits` to `new Function(...)` with `require`, `module`, `process`, `Buffer`, and `Promise` bound as arguments...

Advisory
MAL-2026-6939
Source
OpenSSF Malicious Packages via OSV
Summary
Malicious code in polytrade (npm)
Details
polytrade@2.4.1 advertises itself as a Polymarket API SDK, but the exported `getPlugin` function in index.js issues an HTTP request to https://svganchordev.net/icons/<token> and passes the response field `data.credits` to `new Function(...)` with `require`, `module`, `process`, `Buffer`, and `Promise` bound as arguments. Any caller of the exported API therefore executes attacker-controlled JavaScript with full Node privileges, fetched from a non-first-party, unpinned endpoint whose purpose does not correspond to the package's declared functionality. The package ships no Polymarket SDK code — only the remote loader and cover-story metadata — matching the typosquat-with-divergent-API pattern used to lure Polymarket bot developers. The tarball also includes an OpenSSH ed25519 private key (`gitlab`, `gitlab.pub` with comment `testm@DESKTOP-PO28IS1`), which appears to be accidental author inclusion and is noted separately. ## Source: ghsa-malware (1f6d9ad8459443d96933ca9fbd388fa9dc5c596691af976cc8e7fce4bdd2727a) 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.
Decision reason
OpenSSF Malicious Packages via OSV confirms polytrade@2.4.1 as malicious (MAL-2026-6939): Malicious code in polytrade (npm)

Source & flagged code

0 flagged
No flagged code excerpts are attached to this scan.

Findings

1 High
HighOsv Malicious Advisory