Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Lifecycle Timeline
3Blast Radius
ecosystem impact- 16 npm packages depend on vm2 (5 direct, 11 indirect)
Ecosystem-wide dependent count for version 3.11.3.
DescriptionCVE.org
vm2 is an open source vm/sandbox for Node.js. Prior to 3.11.3, it is possible to catch a host exception using the yield* expression inside an async generator. When the generator is closed using the return function, the value is awaited on and exceptions thrown in the then call will be caught by the runtime and passed to the yield* iterator as the next value. This allows attackers to write code which can escape from the VM2 sandbox and execute arbitrary commands on the host system. This vulnerability is fixed in 3.11.3.
AnalysisAI
Sandbox escape in vm2 (patriksimek/vm2) versions prior to 3.11.3 enables remote code execution on the host Node.js process by abusing async generator yield* semantics to smuggle a host-realm exception into sandbox code, where the attacker pivots through .constructor.constructor to reach process and child_process.execSync. The flaw is exploitable by any attacker who can run JavaScript inside the sandbox, has publicly available exploit code, and carries SSVC technical impact 'total' with automatable=yes, though EPSS remains low at 0.05% (17th percentile) and the CVE is not listed in CISA KEV.
Technical ContextAI
vm2 is a widely-used Node.js library that purports to provide a secure JavaScript sandbox by isolating untrusted code from the host realm via a transformer, a proxy bridge, and overrides of Promise.prototype.then and catch handlers. The root cause is CWE-668 (Exposure of Resource to Wrong Sphere): when an async generator delegates via yield* to an inner iterator lacking a return method, calling i.return(thenable) causes V8's internal PromiseResolveThenableJob to invoke thenable.then in C++ and catch any synchronous throw without going through a JavaScript try/catch or the user-visible Promise.prototype.then. Both of vm2's existing chokepoints - the transformer's catch-clause instrumentation and the globalPromise.prototype.then rejection sanitiser - are bypassed, so a host-realm RangeError triggered by deep recursion inside the V8 resolver job is surfaced to sandbox code unwrapped, exposing the host Function constructor and from there the Node.js process global. CPE coverage is cpe:2.3:a:patriksimek:vm2:* with all versions <= 3.11.2 affected.
RemediationAI
Vendor-released patch: vm2 3.11.3 - upgrade immediately via npm install vm2@3.11.3 or equivalent lockfile update, per the GHSA-248r-7h7q-cr24 advisory (https://github.com/patriksimek/vm2/security/advisories/GHSA-248r-7h7q-cr24) and the fix commit 093494c0c3ef2390d2e56909f9d56e290e6f18b0. Because vm2 has a long history of similar sandbox escapes and is no longer actively maintained as a security boundary, the strongly recommended remediation is to migrate away from vm2 entirely to isolated-vm or to OS-level isolation (separate process, container, V8 isolate, or WASM runtime) for evaluating untrusted code; this is the only durable mitigation against the broader class of escapes and is the path the upstream maintainer has publicly recommended. If immediate migration is not feasible and 3.11.3 cannot be applied right away, do not accept attacker-controlled JavaScript into vm2 - gate the sandbox behind authentication, refuse code submission from untrusted callers, drop privileges on the Node.js process (non-root user, seccomp, read-only filesystem) so a successful escape lands in a constrained environment, and monitor for unexpected child_process spawns from the Node host; the trade-off is that all of these are defense-in-depth and do not actually close the bug.
FortiOS and FortiProxy contain an authentication bypass via the Node.js websocket module allowing unauthenticated remote
Eval injection vulnerability in the internals.batch function in lib/batch.js in the bassmaster plugin before 1.5.2 for t
Flowise version 3.0.5 contains a remote code execution vulnerability in the CustomMCP node. The mcpServerConfig paramete
Node.js 8.5.0 before 8.6.0 allows remote attackers to access unintended files, because a change to ".." handling was inc
An issue was discovered in the node-serialize package 0.0.4 for Node.js. Rated critical severity (CVSS 9.8), this vulner
Directory traversal vulnerability in the st module before 0.2.5 for Node.js allows remote attackers to read arbitrary fi
Multiple SQL injection vulnerabilities in the Manage Accounts page in the AccountManagement.asmx service in the Solarwin
The JS-YAML module before 2.0.5 for Node.js parses input without properly considering the unsafe !!js/function tag, whic
Directory traversal vulnerability in lib/app/index.js in Geddy before 13.0.8 for Node.js allows remote attackers to read
Credential-harvesting malware compromised 84 versions of 42 TanStack npm packages on 2026-05-11 via chained GitHub Actio
Eval injection vulnerability in index.js in the syntax-error package before 1.1.1 for Node.js 0.10.x, as used in IBM Rat
The HTTP server in Node.js 0.10.x before 0.10.21 and 0.8.x before 0.8.26 allows remote attackers to cause a denial of se
Same weakness CWE-668 – Exposure of Resource to Wrong Sphere
View allSame technique Information Disclosure
View allVendor StatusVendor
Share
External POC / Exploit Code
Leaving vuln.today
EUVD-2026-30086
GHSA-248r-7h7q-cr24