Malicious Code Injection in nokire-nana97: A Threat to npm Ecosystem
Summary
MAL-2025-163256: Malicious code in nokire-nana97 (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 package 'nokire-nana97' is part of the npm ecosystem, which is widely used for JavaScript package management. This package is associated with the tea.xyz token reward campaign, which has been known to flood npm with malicious packages. The primary functionality of such packages is to manipulate the npm registry by generating and publishing derivative packages, thereby inflating developer reputation scores for token rewards. This behavior poses a significant risk to developers and users relying on npm for secure package management.
Vulnerability Detail
The vulnerability in 'nokire-nana97' originates from its design to include malicious scripts that automatically modify the package.json file. This modification removes private flags, alters version numbers, and generates random package names, leading to the continuous republishing of variants. The ramifications include pollution of the npm registry, potential exposure of sensitive data, and undermining the integrity of the npm ecosystem. The malicious payload is executed through scripts named auto.js, autopublish.js, autopublish2.js, and autopublish3.js, which are embedded within the package.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall nokire-nana97
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 execution of the malicious scripts by restricting the execution of scripts in your npm configuration. You can do this by running the following command: 'npm config set ignore-scripts true'. However, this may affect the functionality of other packages that rely on scripts for installation.
Conclusion
The 'nokire-nana97' package poses a significant threat to the npm ecosystem due to its malicious code designed to manipulate package metadata and inflate developer reputation scores. It is essential to remove this package and monitor your dependencies for vulnerabilities to maintain the integrity of your applications.
See every vulnerability recorded for nokire-nana97 →
FAQ
The primary risk is the pollution of the npm registry and potential exposure of sensitive data due to the malicious scripts embedded in the package.
You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without requiring any signup.
If you have installed nokire-nana97, you should uninstall it immediately using the command 'npm uninstall nokire-nana97' and review your dependencies for any other potential vulnerabilities.
As of now, there are no known patched versions of nokire-nana97. It is recommended to remove the package entirely.
To prevent similar vulnerabilities, regularly update your dependencies, use trusted packages, and utilize tools like Vulert to monitor for vulnerabilities in your projects.