CVE-2026-22709: Promise callback sanitization bypass in vm2
- Vendor
- Vm2 Project
CVE-2026-22709 is a sandbox escape vulnerability in the vm2 library for Node.js affecting versions before 3.10.2. Callbacks attached to localPromise.prototype.then are sanitized, but callbacks on global Promises returned by async functions are not adequately protected. The globalPromise.prototype.then and globalPromise.prototype.catch implementations use Function.prototype.call, which attacker-controlled sandbox code can intercept to bypass sanitization and obtain unsanitized host error objects. Their constructor chain can expose the host Function constructor, enabling arbitrary code execution outside the sandbox. Version 3.10.1 partially addressed the issue; version 3.10.2 tightened the fix.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation breaks vm2's isolation boundary and enables arbitrary JavaScript and operating-system command execution in the host Node.js environment. The resulting access is bounded by the privileges and external isolation controls of the hosting process, rather than vm2's sandbox restrictions. A proof of concept demonstrates host command execution.
Mitigation
If you can’t patch tonight, do this now.
Until patched, do not execute untrusted code through vm2. Where execution cannot be suspended, isolate the Node.js process in a locked-down container or virtual machine with minimal privileges, no sensitive mounts or secrets, restricted network egress, and strict operating-system security profiles. Apply resource limits and do not treat vm2 as the sole security boundary.
Remediation
Patch, then assume compromise.
Upgrade vm2 to version 3.10.2 or a later supported release, and ensure applications using embedded or forked copies incorporate the fix. The patch replaces interceptable Function.prototype.call invocations in Promise handlers with Reflect.apply. Version 3.10.1 is insufficient because its partial fix remained bypassable.
Exploits
No public exploits tracked yet. Mallory keeps watching.
Affected products & vendors
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
References
Frequently asked questions
- Is CVE-2026-22709 exploited in the wild?
- Yes. As of Oct 6, 2026, Mallory has reports of exploitation in the wild.
- Is there a public exploit for CVE-2026-22709?
- Yes. As of Oct 6, 2026, Mallory has reports of a public exploit for CVE-2026-22709.
- Is there a patch for CVE-2026-22709?
- Upgrade vm2 to version 3.10.2 or a later supported release, and ensure applications using embedded or forked copies incorporate the fix. The patch replaces interceptable Function.prototype.call invocations in Promise handlers with Reflect.apply.
- What products are affected by CVE-2026-22709?
- Vm2 Project Vm2.
- How severe is CVE-2026-22709?
- CVE-2026-22709 has a CVSS v3.1 score of 10.0 (Critical) and an EPSS score of 1.3% (70th percentile) as of Oct 6, 2026.
Recent activity
64 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.