Malicious Code Injection in Respectable Moth-Apptea Package
Summary
MAL-2025-107954: Malicious code in respectable_moth-apptea (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 respectable_moth-apptea package is part of the tea.xyz token reward campaign that has infiltrated the npm ecosystem. This package is designed to facilitate token rewards by generating and publishing derivative packages with randomized names. It aims to inflate developer reputation scores, making it appealing for developers seeking recognition. However, its functionality is compromised by malicious scripts that alter package metadata.
Vulnerability Detail
The vulnerability originates from the presence of autopublish scripts within the respectable_moth-apptea package. These scripts (auto.js, autopublish.js, autopublish2.js, autopublish3.js) are designed to modify the package.json file by removing private flags, changing version numbers, and generating random package names. This behavior leads to the continuous republishing of variants, polluting the npm registry and potentially compromising the integrity of other packages. The ramifications include loss of control over package versions, exposure to malicious code, and damage to developer reputation.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall respectable_moth-apptea
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 respectable_moth-apptea package from your project by executing: npm uninstall respectable_moth-apptea. This will prevent any malicious scripts from executing while you seek a secure alternative.
Conclusion
The respectable_moth-apptea package poses a significant risk due to its malicious code that alters package metadata and repopulates the npm registry with compromised versions. It is crucial for developers to take immediate action by updating or removing the package to protect their projects from potential exploitation.
See every vulnerability recorded for respectable_moth-apptea →
FAQ
It is a package associated with the tea.xyz token reward campaign, designed to inflate developer reputation scores through automated package publishing.
The vulnerability can lead to the introduction of malicious code, modification of package metadata, and potential pollution of the npm registry.
You should update the package to the latest version or remove it from your project to mitigate the risk of exploitation.
Yes, you can use Vulert, which monitors and alerts in real-time for open-source vulnerabilities using just your package-lock.json file.
You can use the Vulert playground at Vulert Scanner to check if your application is affected without requiring any signup.