Improper access control in vm2 - #VU129583
Published: May 4, 2026
vm2
Detailed vulnerability description
The vulnerability allows a remote user to execute arbitrary OS commands on the host.
The vulnerability exists due to improper access control in the NodeVM module resolver when processing sandboxed code in a NodeVM configured with nesting: true. A remote privileged user can require the vm2 package from the sandbox and create a new inner NodeVM with attacker-controlled require settings to execute arbitrary OS commands on the host.
Exploitation requires the host to run untrusted or user-supplied code inside a NodeVM with nesting: true.