Malicious Code Injection in ruji-47 Package: A Threat to npm Ecosystem
Summary
MAL-2025-165274: Malicious code in ruji-47 (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 ruji-47 package is part of a larger set of malicious packages that emerged during the tea.xyz token reward campaign. These packages are designed to manipulate the npm registry by automatically generating and publishing derivative packages with randomized names. The primary functionality of ruji-47 is to inflate developer reputation scores for token rewards, but this comes at the cost of security and integrity within the npm ecosystem.
Vulnerability Detail
The vulnerability in the ruji-47 package stems from its malicious payload, which modifies the package.json file to remove private flags and alters version numbers. It generates random package names, often themed around Indonesian culture, and continuously republishes these variants to pollute the npm registry. This behavior not only compromises the integrity of the npm ecosystem but also poses risks to developers who may unknowingly use these compromised packages, leading to potential security breaches and loss of trust.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall ruji-47
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 measure, you can avoid using the ruji-47 package and any other packages associated with the tea.xyz token reward campaign. Regularly audit your package-lock.json file to identify and remove any suspicious packages.
Conclusion
The ruji-47 package poses a significant threat to the npm ecosystem due to its malicious behavior of altering package metadata and republishing variants. It is crucial for developers to remain vigilant, regularly audit their dependencies, and utilize tools like Vulert to monitor for vulnerabilities. By taking proactive measures, developers can protect their projects from potential security breaches.
See every vulnerability recorded for ruji-47 →
FAQ
The ruji-47 package is a malicious npm package that is part of a campaign to inflate developer reputation scores through the automatic generation of derivative packages.
The vulnerability can compromise the integrity of your project by introducing malicious code that alters your package.json and potentially exposes your application to security risks.
You should immediately uninstall the ruji-47 package using the command npm uninstall ruji-47 and audit your dependencies for any other malicious packages.
You can use tools like Vulert, which monitors your package-lock.json file for open-source vulnerabilities in real-time without requiring code access or installation.
Yes, you can use the Vulert playground at Vulert Scanner to check if your application is affected by the ruji-47 vulnerability without any signup.