Critical Malicious Code Vulnerability in libxmljs9 Package
Summary
MAL-2026-1786: Malicious code in libxmljs9 (npm). Affects libxmljs9 versions 0.30.1. 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
libxmljs9 is a popular library in the npm ecosystem that provides a JavaScript interface for parsing and manipulating XML documents. It is widely used in various applications for its ability to handle XML data efficiently. However, this package has been identified with a critical vulnerability that exposes users to potential malicious code execution.
Vulnerability Detail
The vulnerability in libxmljs9 stems from the presence of malicious code that can compromise the integrity of applications using this library. This issue was reported by ReversingLabs and affects version 0.30.1 of the package. If exploited, this vulnerability could allow attackers to execute arbitrary code, leading to unauthorized access, data breaches, or system compromise. The malicious code is embedded within the package, making it difficult for users to detect without proper security measures.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall libxmljs9
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, users can avoid using the affected version (0.30.1) of libxmljs9 until a patch is applied. It is advisable to review your project's dependencies and consider alternative libraries for XML parsing that do not have known vulnerabilities.
Conclusion
The libxmljs9 package has a critical vulnerability due to malicious code that can compromise applications. Users are strongly advised to update to the latest version to protect against potential exploits. Regular monitoring of dependencies and prompt updates are essential practices for maintaining application security.
See every vulnerability recorded for libxmljs9 →
FAQ
The vulnerability involves malicious code that can execute arbitrary commands, potentially compromising the security of applications using the library.
You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without needing to sign up.
Immediately update the package to the latest version using 'npm install libxmljs9@latest' to mitigate the risk of exploitation.
Regularly monitor your dependencies for vulnerabilities using tools like Vulert and keep your packages updated to the latest secure versions.
Consider using alternative libraries for XML parsing or implement strict security measures to limit the impact of potential exploits until you can update.