Malicious Code Injection in pitra-42: A Threat to npm Packages
Summary
MAL-2025-164313: Malicious code in pitra-42 (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
pitra-42 is an npm package that has been identified as part of a malicious campaign targeting the npm ecosystem. This package is associated with the tea.xyz token reward initiative, which aims to inflate developer reputation scores by flooding the npm registry with derivative packages. The malicious nature of pitra-42 lies in its ability to modify package metadata and republish variants, thereby compromising the integrity of the npm registry.
Vulnerability Detail
The vulnerability in pitra-42 originates from its design to execute autopublish scripts that alter the package.json file. These scripts remove private flags, change version numbers, and generate random package names, which leads to the pollution of the npm registry. The ramifications include potential security risks for developers who unknowingly use these compromised packages, as well as the degradation of the npm ecosystem's reliability.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall pitra-42
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 pitra-42 and any packages that depend on it. Regularly audit your npm packages using tools like npm audit to identify and mitigate vulnerabilities.
Conclusion
The pitra-42 package poses a significant threat to the npm ecosystem due to its malicious behavior of modifying package metadata and republishing variants. It is crucial for developers to remove this package and monitor their dependencies to maintain the integrity of their projects.
See every vulnerability recorded for pitra-42 →
FAQ
pitra-42 is an npm package involved in a malicious campaign that modifies package metadata and floods the npm registry with derivative packages.
Using pitra-42 can compromise your project's integrity by introducing malicious code and polluting the npm registry with unreliable packages.
You can use Vulert, which monitors and alerts for open-source vulnerabilities in real-time. Visit Vulert Scanner to check your application without any signup.
You should uninstall pitra-42 immediately using 'npm uninstall pitra-42' and check your package-lock.json for any lingering references.
Yes, tools like npm audit and Vulert can help you identify and manage vulnerabilities in your npm packages effectively.