Malicious Code Injection in wulan-4 Package: A Threat to npm Users
Summary
MAL-2025-170565: Malicious code in wulan-4 (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
The wulan-4 package is part of the npm ecosystem, primarily used for various JavaScript functionalities. It has been identified as part of a malicious campaign that exploits npm's package management system. This package is linked to the tea.xyz token reward initiative, which has been known to flood the npm registry with harmful packages designed to manipulate developer reputation scores.
Vulnerability Detail
The vulnerability in the wulan-4 package stems from its malicious code that modifies the package.json file. This code removes private flags, alters version numbers, and generates random package names, contributing to the pollution of the npm registry. The malicious payload is designed to automatically publish derivative packages, which can lead to significant security risks, including the potential for unauthorized access to sensitive data and the degradation of the npm ecosystem's integrity.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall wulan-4
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, you can remove the wulan-4 package from your project by executing the following command: npm uninstall wulan-4. This will prevent any malicious code from executing until a secure version is available.
Conclusion
The wulan-4 package poses a significant security risk due to its malicious code designed to manipulate npm's package management system. Users are advised to uninstall the package and monitor for updates. Utilizing tools like Vulert can enhance your project's security by providing real-time vulnerability alerts.
See every vulnerability recorded for wulan-4 →
FAQ
The wulan-4 package is a JavaScript library available on npm, which has been identified as part of a malicious campaign targeting npm users.
The malicious code modifies your package.json file, potentially leading to unauthorized package republishing and security vulnerabilities in your project.
You should uninstall the wulan-4 package immediately and monitor for any updates or patches that address this vulnerability.
You can use tools like Vulert, which monitors your package-lock.json for open-source vulnerabilities in real-time. You can check your application using the Vulert playground without any signup.
Regularly updating your dependencies, using tools like Vulert for monitoring, and conducting security audits can help prevent similar vulnerabilities.