Malicious Code Injection in amjadharun Package: A Threat to npm Ecosystem
Summary
MAL-2025-170841: Malicious code in amjadharun (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 amjadharun package is part of the npm ecosystem, which is widely used for JavaScript package management. This package is associated with a token reward campaign that has been identified as malicious. It is designed to inflate developer reputation scores by generating and publishing numerous derivative packages with randomized names, which can lead to significant pollution of the npm registry.
Vulnerability Detail
The vulnerability in the amjadharun package originates from its involvement in a malicious campaign that modifies the package.json file to remove private flags and alters version numbers. It generates random package names, primarily themed around Indonesian culture, and continuously republishes these variants. This behavior can lead to a compromised npm registry, making it difficult for developers to trust legitimate packages and potentially exposing them to further security risks.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall amjadharun
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 amjadharun package from your project by executing the following command: npm uninstall amjadharun. This will prevent any malicious code from executing until a proper fix is applied.
Conclusion
The amjadharun package poses a significant threat to the npm ecosystem due to its malicious behavior of modifying package files and republishing variants. It is crucial for developers to take immediate action by uninstalling the package and monitoring their projects for vulnerabilities to maintain the integrity of their applications.
See every vulnerability recorded for amjadharun →
FAQ
The amjadharun package is an npm package that has been identified as part of a malicious campaign aimed at inflating developer reputation scores through the generation of numerous derivative packages.
The vulnerability can lead to the pollution of the npm registry, making it difficult to trust legitimate packages and potentially exposing your project to security risks.
You should uninstall the amjadharun package immediately and check for any updates or patches that may address this vulnerability.
You can use Vulert, which monitors and alerts for open-source vulnerabilities in your software using just the package-lock.json file. You can check if your application is affected by visiting the Vulert playground.
Regularly updating your packages, using tools like Vulert for monitoring vulnerabilities, and reviewing package dependencies can help prevent similar issues in the future.