Malicious Code Injection in gracewhite Package: A Threat to npm Users
Summary
MAL-2025-171278: Malicious code in gracewhite (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 gracewhite package is part of the npm ecosystem, which is widely used for JavaScript package management. It is often utilized by developers to manage dependencies in their projects. However, this package has been identified as part of a malicious campaign that aims to exploit npm's publishing system, leading to potential security risks for users who incorporate it into their applications.
Vulnerability Detail
The vulnerability in the gracewhite package originates from its association with the tea.xyz token reward campaign, which floods the npm registry with malicious packages. These packages contain scripts designed to automatically publish derivative packages with altered metadata, including the removal of private flags and the generation of random package names. This behavior can lead to the pollution of the npm registry, making it difficult for developers to trust the integrity of packages and potentially exposing their applications to further vulnerabilities.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall gracewhite
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 workaround, you can avoid using the gracewhite package altogether and look for alternative packages that provide similar functionality without the associated risks. Always verify the reputation and integrity of packages before including them in your project.
Conclusion
The gracewhite package poses a significant security risk due to its malicious nature and association with a campaign designed to exploit the npm registry. It is crucial for developers to be vigilant, regularly update their dependencies, and utilize tools like Vulert to monitor for vulnerabilities in their applications.
See every vulnerability recorded for gracewhite →
FAQ
The gracewhite package is an npm package that has been identified as part of a malicious campaign aimed at exploiting the npm registry.
The vulnerability can lead to the pollution of the npm registry, making it difficult to trust the integrity of packages and potentially exposing your application to further security risks.
You should uninstall the gracewhite package immediately using 'npm uninstall gracewhite' to mitigate any potential risks.
You can use Vulert, which monitors and alerts in real-time for open-source vulnerabilities in your software by analyzing your package-lock.json file.
Yes, you can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without requiring any signup.