Malicious Code Vulnerability in pilka-luiu-knni Package
Summary
MAL-2025-164193: Malicious code in pilka-luiu-knni (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 pilka-luiu-knni package is part of a series of npm packages that have been associated with the tea.xyz token reward campaign. These packages are designed to inflate developer reputation scores by automatically generating and publishing derivative packages with randomized names. This behavior poses a significant risk to the integrity of the npm registry and can lead to the proliferation of malicious software.
Vulnerability Detail
The vulnerability in the pilka-luiu-knni package stems from its malicious code that modifies the package.json file to remove private flags and change version numbers. It generates random package names, often themed around Indonesian culture, and continuously republishes these variants to pollute the npm registry. This not only compromises the security of applications using this package but also undermines the trustworthiness of the npm ecosystem.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall pilka-luiu-knni
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 pilka-luiu-knni package from your project by executing the following command: npm uninstall pilka-luiu-knni. This will prevent any malicious code from executing in your application until a secure version is available.
Conclusion
The pilka-luiu-knni package contains a serious vulnerability due to its malicious code that alters package metadata and floods the npm registry with harmful variants. It is crucial to take immediate action by updating or removing the package to protect your application from potential threats.
See every vulnerability recorded for pilka-luiu-knni →
FAQ
The pilka-luiu-knni package is an npm package associated with a token reward campaign that generates and publishes derivative packages to inflate developer reputation scores.
The vulnerability allows malicious code to modify your package.json file, potentially leading to the installation of unwanted or harmful packages in your application.
Yes, you can use Vulert, which monitors and alerts for open-source vulnerabilities in your software using just package-lock.json. You can check your application for vulnerabilities without any signup at the Vulert playground.
If an immediate update is not possible, consider uninstalling the package as a temporary measure to mitigate the risk of exploitation.
You can find detailed information about this vulnerability in the Open Source Vulnerability database or by visiting the GitHub repository for malicious packages.