Malicious Code Detected in node-calculator-0c8f Package
Summary
MAL-2025-190526: Malicious code in node-calculator-0c8f (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 node-calculator-0c8f package is a JavaScript library available on npm that provides basic arithmetic operations. It is designed for developers looking to integrate simple calculation functionalities into their applications. However, this package has been identified to contain malicious code, posing significant risks to users who incorporate it into their projects.
Vulnerability Detail
The vulnerability originates from the malicious code embedded within the node-calculator-0c8f package. This code can potentially compromise the security of applications that utilize this package, leading to unauthorized access, data breaches, or other malicious activities. The specific technical details of the malicious behavior have not been disclosed, but the presence of such code is a critical concern for developers relying on this package.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall node-calculator-0c8f
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 replace the functionality provided by node-calculator-0c8f with alternative libraries that are known to be secure, such as mathjs or decimal.js. For example, to use mathjs, you can install it using npm: npm install mathjs, and then import it in your code:
const math = require('mathjs');
Conclusion
The node-calculator-0c8f package has been identified as containing malicious code, which poses a serious threat to applications that utilize it. Developers are advised to remove this package and consider secure alternatives. Regular monitoring for vulnerabilities using tools like Vulert can help maintain the security of your projects.
See every vulnerability recorded for node-calculator-0c8f →
FAQ
node-calculator-0c8f is a JavaScript library that provides basic arithmetic operations for developers.
The specific details of the malicious code have not been disclosed, but it poses significant security risks.
You can use Vulert's playground at Vulert Scanner to check if your application is affected without needing to sign up.
You should remove the package immediately and consider using alternative libraries for your calculation needs.
Yes, Vulert can monitor and alert you in real-time for open-source vulnerabilities using just your package-lock.json file.