Malicious Code Detected in styled-components-react18-v5 Package
Summary
MAL-2025-5462: Malicious code in styled-components-react18-v5 (npm). Affects styled-components-react18-v5 versions >= 99.99.2. 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
styled-components-react18-v5 is an npm package that allows developers to use styled-components in React 18 applications. It provides a way to style React components using tagged template literals, enabling a more dynamic and component-based approach to styling. However, this package has been identified as having a vulnerability that allows it to communicate with a domain associated with malicious activity, potentially compromising the security of applications that utilize it.
Vulnerability Detail
The vulnerability in styled-components-react18-v5 stems from its communication with a domain linked to malicious activities. This could lead to unauthorized data access, data exfiltration, or other security breaches within applications using this package. The issue was introduced in version 99.99.2, making it critical for developers to be aware of the risks associated with this version and to take immediate action to mitigate potential threats.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall styled-components-react18-v5
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
As a temporary workaround, consider removing the styled-components-react18-v5 package from your project until a secure version is released. You can do this by running: npm uninstall styled-components-react18-v5. Alternatively, you may explore using a different styling solution that does not have this vulnerability.
Conclusion
The styled-components-react18-v5 package has been identified with a serious vulnerability that allows it to communicate with a malicious domain. Developers using this package should take immediate action to update or remove it to protect their applications. Utilizing tools like Vulert can help in monitoring and identifying vulnerabilities in real-time.
See every vulnerability recorded for styled-components-react18-v5 →
FAQ
The vulnerability involves the package communicating with a domain associated with malicious activity, posing risks to application security.
You can use Vulert, which monitors and alerts for open-source vulnerabilities in real-time. Visit Vulert Scanner to check your application without needing to sign up.
If an immediate update is not possible, consider removing the package or using an alternative styling solution until a secure version is available.
The vulnerability was introduced in version 99.99.2. It is crucial to update to a version that is confirmed to be secure.
For more details, you can reach out to the finder of this vulnerability, Amazon Inspector, at actran@amazon.com.