Malicious Code Injection in classical_horse_requirement Package
Summary
MAL-2025-93573: Malicious code in classical_horse_requirement (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 classical_horse_requirement package is part of the npm ecosystem, primarily used for managing dependencies in JavaScript applications. This package has been identified as part of a malicious campaign that floods the npm registry with harmful packages. Its key attributes include the ability to modify package metadata and republish itself under various names, which can lead to significant security risks for developers using it.
Vulnerability Detail
The vulnerability stems from malicious code embedded within the classical_horse_requirement package. This code is designed to alter the package.json file by removing private flags, changing version numbers, and generating random package names. The origin of this vulnerability is linked to a campaign aimed at inflating developer reputation scores for token rewards, resulting in a polluted npm registry. The ramifications include potential exposure of sensitive information, compromised application integrity, and increased difficulty in managing dependencies due to the proliferation of malicious packages.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall classical_horse_requirement
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 prevent the installation of this package by using npm's package-lock.json to monitor your dependencies. Additionally, consider using tools like Vulert to check for vulnerabilities in your application. You can access the Vulert playground at https://vulert.com/scanner to see if your application is affected without any signup.
Conclusion
The classical_horse_requirement package poses a significant security risk due to its malicious code designed to manipulate package metadata. It is crucial for developers to uninstall this package and monitor their applications for vulnerabilities using tools like Vulert. By staying vigilant and proactive, you can protect your applications from potential threats.
See every vulnerability recorded for classical_horse_requirement →
FAQ
It is an npm package that has been identified as part of a malicious campaign to manipulate package metadata and inflate developer reputation scores.
The malicious code can modify your package.json file, potentially exposing sensitive information and leading to the installation of more harmful packages.
You should uninstall the classical_horse_requirement package immediately and check for any dependencies that may rely on it.
Yes, you can use Vulert, which monitors your package-lock.json for vulnerabilities in real-time. You can check your application at Vulert Scanner.
Uninstalling the package may affect your application if it relies on it. Ensure to review your dependencies and test your application after making changes.