Critical Malicious Code Vulnerability in @afetcan/api Package
Summary
MAL-2025-191179: Malicious code in @afetcan/api (npm). Affects @afetcan/api versions 0.0.13. 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 @afetcan/api package is a Node.js library designed for API interactions, providing developers with tools to streamline their application development. However, it has recently been compromised, making it susceptible to a severe security threat that can lead to unauthorized access and data breaches.
Vulnerability Detail
The vulnerability stems from a malicious code injection by the Sha1-Hulud: The Second Coming NPM worm. This worm is designed to steal tokens and credentials from users and publish them to GitHub. It can propagate itself to other NPM packages owned by the user and establish persistence through a GitHub action. Additionally, the worm has the potential to destroy the user's home directory, leading to significant data loss.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall @afetcan/api
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, consider removing the @afetcan/api package from your project until a secure version is released. You can do this by running: npm uninstall @afetcan/api. Additionally, monitor your project for any suspicious activity and review your GitHub actions for unauthorized changes.
Conclusion
The @afetcan/api package has been compromised by a malicious worm that poses serious security risks. It is essential for developers using this package to take immediate action by updating or removing the package and monitoring their projects for any suspicious activity. Utilizing tools like Vulert can help in identifying and managing vulnerabilities effectively.
See every vulnerability recorded for @afetcan/api →
FAQ
The vulnerability involves a malicious worm that steals sensitive information and can propagate to other packages.
You can check your project for vulnerabilities using tools like Vulert, which monitors your package-lock.json for known issues.
If you suspect a compromise, immediately revoke any exposed tokens and credentials, and review your code and GitHub actions for unauthorized changes.
Regularly update your dependencies, use tools like Vulert for monitoring, and conduct security audits on your codebase.
Detailed information can be found in the vulnerability report on GitHub and through security advisories related to the @afetcan/api package.