Critical Malicious Code Vulnerability in jsonapptoken Package
Summary
MAL-2025-192808: Malicious code in jsonapptoken (npm). Affects jsonapptoken versions 2.3.8. 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 jsonapptoken package is a Node.js library used for generating JSON Web Tokens (JWTs) for secure API authentication. It is widely utilized in various applications to manage user sessions and secure data transmission. However, this package has been identified to contain malicious code that poses significant security risks to applications relying on it.
Vulnerability Detail
The vulnerability in the jsonapptoken package arises from the inclusion of malicious code that can compromise the integrity of applications using this library. This code can potentially allow attackers to execute arbitrary commands, leading to unauthorized access to sensitive data or system resources. The malicious behavior was introduced in version 2.3.8, as identified by ReversingLabs, and poses a serious threat to any application that has integrated this version.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall jsonapptoken
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
If immediate updating is not feasible, consider removing the jsonapptoken package from your project and replacing it with an alternative JWT library that is known to be secure. Additionally, you can monitor your application for any suspicious activities until the package is updated.
Conclusion
The jsonapptoken package has a critical vulnerability due to the presence of malicious code. It is crucial for developers to update to a secure version or find alternatives to mitigate risks. Utilizing tools like Vulert can help in monitoring for such vulnerabilities effectively.
See every vulnerability recorded for jsonapptoken →
FAQ
The jsonapptoken package is used for generating JSON Web Tokens (JWTs) for secure API authentication in Node.js applications.
You can check if your application is affected by using Vulert, which monitors and alerts for open-source vulnerabilities in real-time. Visit Vulert Scanner to analyze your package-lock.json without any signup.
If you cannot update the package right away, consider removing it and using a different JWT library, and monitor your application for any unusual behavior.
The vulnerability was discovered by ReversingLabs, a cybersecurity firm specializing in threat intelligence.
The consequences include unauthorized access to sensitive data, execution of arbitrary commands, and potential compromise of the entire application.