Host code execution via custom inspect callback
Published Jul 21, 2023 · Updated Nov 3, 2025
Sandbox escape in Patrik Simek vm2 before 3.10.3 allows attackers to execute arbitrary host code through a custom inspect callback. A cross-realm Symbol.for key installs a Node.js custom inspect callback; WebAssembly.compileStreaming triggers host-side inspection and leaks the host inspect function into sandbox code. The attacker must already control JavaScript executed inside a vm2 sandbox; successful escape runs code with the host Node.js process's privileges.
Summary
What happened
Sandbox escape in Patrik Simek vm2 before 3.10.3 allows attackers to execute arbitrary host code through a custom inspect callback. A cross-realm Symbol.for key installs a Node.js custom inspect callback; WebAssembly.compileStreaming triggers host-side inspection and leaks the host inspect function into sandbox code. The attacker must already control JavaScript executed inside a vm2 sandbox; successful escape runs code with the host Node.js process's privileges.
The record
- CVE
- CVE-2023-37903
- Published
- Jul 21, 2023
- Updated
- Nov 3, 2025
- Vendor
- Patrik Simek
- Product
- vm2
- Classifications
- CWE-78, T1059.007
- Attack vector
- network
- Privileges
- unauthenticated
Timeline
How it unfolded
- Jul 21, 2023CVE publishedPublication date reported by the CVE source.
- Nov 3, 2025Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=<= 3.9.19
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
- Sandbox Escape in vm2 3.9.19 via custom inspect functionproof of concept · demonstrated
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo