vite-react-toolkit@1.0.1
Malicious code in vite-react-toolkit (npm)
Analysis
vite-react-toolkit@1.0.1 (published by [account] The file src/features/extras/config.js is a self-executing IIFE that fetches attacker-controlled JavaScript from hxxps://www[.]jsonkeeper[.]com/b/AAON3 using axios, then passes it through new Function("require", code) for arbitrary code execution. It is auto-imported as a module side-effect via src/features/plugins.js line 2 (import './extras/config.js'), meaning any require() or import of the package triggers the payload immediately — no lifecycle hooks needed. The payload retries up to 5 times and suppresses console.log to hide failure. The C2 host jsonkeeper[.]com allows the attacker to serve arbitrary updated payloads at any time.
- analyzed by
- Leitwacht
- first seen
- Jun 12, 2026, 05:20 AM
- analyzed
- Jun 12, 2026, 05:20 AM
Related advisories
- obfus-jsxy@3.2.0
- vite-tsconfig@1.1.2
- bubblestring@1.1.4
- node-env-resolve@1.0.0
- hex-type@3.0.2
- prettier_v2@3.8.5
- win-build-utils@1.0.0
- prettier_v1@3.8.4
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.