CVE-2026-24118
Node.js (vm2) · vm2
A sandbox breakout vulnerability in the Node.js vm2 library allows attackers to escape the sandbox and execute arbitrary commands on the host system.
Executive summary
A critical sandbox breakout vulnerability in vm2 allows attackers to escape the virtual environment and achieve arbitrary command execution on the host.
Vulnerability
The vulnerability allows an attacker to break out of the vm2 sandbox environment. By crafting specific code, an attacker can bypass security restrictions and execute arbitrary commands directly on the host system running the Node.js application.
Business impact
With a CVSS score of 9.8, this flaw represents a complete failure of the isolation mechanism. If a Node.js application uses vm2 to process untrusted input, an attacker can gain full access to the underlying server, potentially compromising all data and services hosted on that machine.
Remediation
Immediate Action: Update the vm2 dependency to version 3.11.0 or later immediately.
Proactive Monitoring: Review application logs for unusual child process creation or unauthorized file system access originating from the Node.js application.
Compensating Controls: Run the Node.js application within a containerized environment (e.g., Docker) with restricted capabilities and no root privileges to limit the impact of a potential breakout.
Exploitation status
Public Exploit Available: No
Analyst recommendation
The vm2 library is inherently difficult to secure, and this breakout vulnerability highlights the risks of relying on it for sandboxing untrusted code. Organizations must update to the latest version and consider adopting stronger isolation methods, such as hardware-based virtualization or separate, hardened processes.