Description
vm2 is an open source vm/sandbox for Node.js. Prior to 3.11.0, vm2's code transformer has a performance optimization that skips AST analysis when the code does not contain catch, import, or async keywords. This fast-path bypass allows sandboxed code to directly access the internal VM2_INTERNAL_STATE_DO_NOT_USE_OR_PROGRAM_WILL_FAIL variable, which exposes internal security functions (handleException, wrapWith, import). This vulnerability is fixed in 3.11.0.
Affected products
vm2_project: vm2
References2
- github.com/patriksimek/vm2/security/advisories/GHSA-wp5r-2gw5-m… ExploitMitigationVendor Advisory
- github.com/patriksimek/vm2/security/advisories/GHSA-wp5r-2gw5-m… ExploitMitigationVendor Advisory
Metrics
- CVSS 3.1
-
5.8
MEDIUM
Score source: NVD
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N - EPSS — exploit probability
- 0% percentile: 16 · as of 14 November 2026
- CWE
- CWE-693
Could this be exploited in your environment?
A patch closes the known hole. A penetration test shows what an attacker can still reach — with proof.