Security Digest · Vulnerability record
CVE-2026-47686: VM2 has Missing Error.cause Sanitization that Enables Sandbox Escape to RCE
vm2 is an open source vm/sandbox for Node.js.
CVSS 9.9 Critical EPSS 0.6% · p47 Check exposure
Should you act?
Critical, preconditions apply
Severe if exploited, but exploitation needs conditions that may not apply to you. This signal is computed from CISA KEV, EPSS and CVSS data; it is not an editorial verdict.
- No confirmed exploitation. It is not in CISA’s KEV catalog and CISA’s SSVC assessment records no known exploitation. That can change quickly after a public write-up; re-check if you are affected.
- EPSS 0.6%, percentile 47: FIRST’s model estimates a 0.6% chance of exploitation activity in the next 30 days, higher than 47% of all scored CVEs (low). EPSS is a probability, not a verdict.
- Needs an account (low (any account)). Exposure depends on who can log in.
- Only applies if your dependency tree includes
vm2(npm) <= 3.11.5, fixed in 3.11.6. Check your lockfile, including transitive dependencies. - Editorial verdict: Check exposure. vm2: 22 Critical Sandbox Escapes, Fixed in 3.12.2 — If anything outside your trust boundary can get code into vm2, upgrade to 3.12.2 today and plan to move that code out of process; if vm2 only runs your own code, upgrade on a normal cycle.
What it is
vm2 is an open source vm/sandbox for Node.js. Prior to 3.11.6, handleException() in lib/setup-sandbox.js sanitizes SuppressedError.error, SuppressedError.suppressed, and AggregateError.errors but does not sanitize Error.cause, allowing sandbox code to obtain a powerful host object such as process from an embedder-exposed host function that throws an error with that object as its cause and then execute arbitrary host commands. This issue is fixed in version 3.11.6.
From the GitHub advisory
Affected: vm2
Summary
I found that handleException() in lib/setup-sandbox.js recursively sanitizes sub-errors for SuppressedError and AggregateError, but completely ignores the ES2022 Error.cause property. When sandbox code catches a host-thrown error carrying a .cause that references a host object like process, it can traverse that reference to achieve arbitrary command execution on the host.
The project's own docs/ATTACKS.md (Defense Invariant #3, line 54) explicitly claims Error.cause is sanitized. The implementation does not match this claim.
Root Cause
Weakness type: CWE-693.
Product: vm2 (npm) · Assigned by: GitHub_M · Published: 2026-08-17
Affected and fixed versions
| Ecosystem | Package | Vulnerable | First fixed |
|---|---|---|---|
| npm | vm2 | <= 3.11.5 | 3.11.6 |
| Vendor | Product | Affected versions (per CVE record) |
|---|---|---|
| patriksimek | vm2 | < 3.11.6 |
Severity scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| GitHub_M | 3.1 | 9.9 Critical | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
| GitHub | 3.1 | 9.9 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
- Attack vector: network (remotely reachable)
- Attack complexity: low
- Privileges required: low (any account)
- User interaction: none
- Scope: changed (can affect other components)
CVSS measures how bad a flaw is if exploited, not how likely exploitation is. Read it next to the exploitation data below.
Exploitation and urgency
- CISA KEV: not listed (no confirmed in-the-wild exploitation known to CISA).
- CISA SSVC assessment: exploitation none, automatable no, technical impact total.
- FIRST EPSS (model of 2026-10-21): 0.58% probability of exploitation activity in the next 30 days; percentile 47.
Timeline
- — CVE record published by GitHub_M
- — GitHub-reviewed advisory GHSA-m283-3h24-438v published (critical)
- — erroneo.us brief: vm2: 22 Critical Sandbox Escapes, Fixed in 3.12.2
- — CVE record last updated
Sources and references
Original sources first. Version and fix details should always be confirmed against the vendor or project advisory.
Vulnerability records
- GitHub Advisory GHSA-m283-3h24-438v github.com
- CVE.org record CVE-2026-47686 cve.org
- NVD entry CVE-2026-47686 nvd.nist.gov
Other references from the CVE record and advisory
- github.com github.com
- github.com github.com
- github.com github.com