Critical Malicious Code Vulnerability in react-svg-module
Summary
MAL-2025-190572: Malicious code in react-svg-module (npm). Affected versions are not published. No fix is published. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
react-svg-module is an npm package designed for rendering SVG images in React applications. It allows developers to easily integrate scalable vector graphics into their projects, enhancing visual appeal and interactivity. However, this package has been compromised, leading to severe security risks for any application utilizing it.
Vulnerability Detail
The vulnerability stems from the presence of malicious code embedded within the react-svg-module package. This code can fully compromise any computer that has the package installed, potentially allowing unauthorized access to sensitive information, including secrets and keys. The malicious nature of this code has been confirmed by security researchers, and it poses a significant threat to the integrity of affected systems.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall react-svg-module
If it arrived as a transitive dependency, remove the package that pulled it in, then reinstall.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
Currently, the best workaround is to uninstall the react-svg-module package from your project. You can do this by running the command: npm uninstall react-svg-module. This action will help mitigate the risk while you seek alternative solutions for rendering SVGs in your application.
Conclusion
The react-svg-module package has been identified as containing malicious code that poses a serious threat to any system using it. Immediate action is required to remove the package and secure any sensitive information. Utilizing tools like Vulert can help monitor for such vulnerabilities in the future.
See every vulnerability recorded for react-svg-module →
FAQ
react-svg-module is an npm package that allows developers to render SVG images in React applications, enhancing the visual quality and interactivity of web applications.
The malicious code can compromise your system by allowing unauthorized access to sensitive information, potentially leading to data breaches and loss of control over your environment.
If you have react-svg-module installed, you should immediately uninstall it and rotate any secrets or keys stored on the affected system.
Yes, you can use Vulert, a tool that monitors and alerts for open-source vulnerabilities in real-time. You can check your application using the Vulert playground without any signup.
While removing the package is essential, there is no guarantee that all malicious software resulting from its installation will be removed. It is advisable to conduct a thorough security audit of your system.