CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-92941

CVE-2026-92941: Sandbox Escape and Process-Wide TLS Trust Store Manipulation in vm2

Amit Schendel
Amit Schendel
Senior Security Researcher

Oct 2, 2026·10 min read·42 visits

Executive Summary (TL;DR)

A critical flaw in vm2 (3.11.3-3.11.6) allows sandboxed code to bypass isolation and overwrite the global Node.js root CAs, enabling complete Man-in-the-Middle compromise of outbound host HTTPS connections.

CVE-2026-92941 is a critical sandbox-escape and trust-manipulation vulnerability in the vm2 library (versions 3.11.3 to 3.11.6). This security flaw allows untrusted code executing within a NodeVM sandbox environment to compromise the global TLS trust store of the host Node.js process. By leveraging a design flaw where the host's native 'tls.setDefaultCACertificates' can be executed via a proxy wrapper, combined with a bridge unwrapping bypass in the 'url' module, an attacker can modify the process-wide default root Certificate Authorities. Consequently, all subsequent outbound TLS/HTTPS clients running on the host thread are forced to trust attacker-signed certificates, facilitating transparent Man-in-the-Middle (MitM) attacks. The vulnerability was resolved in version 3.11.7 of vm2 by introducing built-in member-level sanitization before applying read-only proxy wrappers.

Vulnerability Overview

The sandboxing library vm2 provides an isolated context within Node.js to execute untrusted code. To facilitate interaction with the outside host environment, developers can explicitly authorize the loading of built-in modules like tls and url. When these modules are loaded, vm2 wraps them in a read-only Proxy to prevent sandboxed code from modifying their properties or inserting malicious bindings directly. However, this Proxy architecture does not restrict method execution, creating an attack vector when a permitted module contains a function that alters global process state rather than instance properties.

CVE-2026-92941 is a critical vulnerability affecting vm2 versions 3.11.3 through 3.11.6. It allows sandboxed JavaScript scripts to escape isolation and manipulate the global TLS trust store of the host process. This vulnerability is classified under CWE-732 (Incorrect Permission Assignment for Critical Resource) and carries a CVSS base score of 10.0. The vulnerability relies on the presence of the tls and url built-ins in the NodeVM instance, enabling attackers to replace the default Certificate Authority (CA) root certificates of the host.

The cryptographic consequence of this vulnerability is significant. Any subsequent TLS or HTTPS connection initiated by the host Node.js process will rely on the compromised root CA store. If an attacker controls the newly injected CA certificates, they can execute transparent man-in-the-middle attacks on the host process's outbound traffic. This allows for session hijacking, credential harvesting, and remote command execution if the host downloads and executes serialized data or updates from external services.

This report details the architectural failure that allowed sandboxed code to influence process-wide cryptographic configuration. It analyzes the specific bridge unwrapping bypass that circumvented native type enforcement. Finally, it outlines the official remediation, evaluates the long-term viability of the patch, and provides concrete mitigation and detection rules to identify active exploitation.

Root Cause Analysis

The core architecture of vm2 relies on ES6 Proxies to enforce a boundary between the sandbox and the host. When a module is loaded via hostRequire, vm2 executes the vm.readonly(hostRequire(key)) method to wrap the module. The proxy intercepts property mutations (set, defineProperty, deleteProperty), returning errors when sandboxed code attempts to alter the module. However, the proxy is transparent to method invocation, meaning calling a method on the proxy forwards the execution back to the host realm with the host process's full privilege set.

This mechanism fails to maintain sandboxing invariants when exposed to APIs that mutate process-level settings. The native Node.js tls.setDefaultCACertificates method is a process-wide API that alters the root CA trust store inside the underlying OpenSSL library. Since vm.readonly only prevents property mutation on the tls module export object, it does not intercept or restrict the calling of setDefaultCACertificates. This allows sandboxed code to execute the method and target the host process configuration directly.

Although sandboxed code can call the method, native Node.js methods execute strict type checks on arguments within C++ space. The tls.setDefaultCACertificates method expects an array of strings representing PEM-encoded certificates. If a sandboxed array is passed, the native runtime detects that the object is a proxy-wrapped sandbox array rather than a native host-realm array, throwing a type error. This type enforcement acts as a secondary barrier that normally prevents host process manipulation from within the sandbox.

To execute a successful sandbox escape, an attacker must bypass this marshalling constraint by obtaining a raw, unwrapped host-realm array. Because vm2 maintains performance by dynamically unwrapping certain host-originated structures, developers must carefully vet all methods on allowed modules. The combination of unchecked process-wide configuration methods and implicit object unwrapping allows malicious scripts to circumvent security assumptions and alter host settings.

The Bridge Unwrapping Trick

The critical bypass that enables exploitation of CVE-2026-92941 involves leveraging the native url module to forge a host-realm array. Under normal operation, the vm2 bridge translates objects between the host and sandbox environments. If a host-native function returns an object to the sandbox, the bridge intercepts the transfer. However, when certain built-in objects are returned, vm2 must unwrap them during subsequent calls back to the host to maintain compatibility with native internal APIs.

The URLSearchParams.prototype.getAll method satisfies the precise requirements needed to craft an exploit payload. When called, it produces a standard JavaScript array containing query parameter values. Because url is a host-native module, the array returned by getAll is allocated in the host realm. Although the sandboxed environment receives a reference to this array, the underlying object remains a genuine host-realm array, which vm2 recognizes.

When the sandboxed script passes this host-originated array back to tls.setDefaultCACertificates, the vm2 bridge performs automatic unwrapping. The bridge extracts the underlying host-realm array reference to satisfy the expectations of the native C++ function. Because the unwrapped object is a genuine, native host-realm array, the C++ validation logic inside Node.js passes without error, allowing the malicious PEM certificate payload to be accepted as the new default CA list.

This interaction highlights the complexity of enforcing security boundaries in mixed-realm environments. A security boundary is only as strong as its weakest bridge mapping. By combining an allowed module that modifies global state with an allowed module that returns unwrapped native containers, the attacker constructs a complete chain of execution that subverts both the proxy-based write protection and the native runtime type checks.

Exploitation Methodology

To exploit this vulnerability, the target application must run a vulnerable version of vm2 with a configuration that allows both the tls and url built-in modules. This configuration is common in applications that handle external network requests or perform URL parsing and network client operations. The attacker must have the ability to supply arbitrary JavaScript code for execution within the sandboxed context, which is typical in plug-in platforms, code-evaluation APIs, and serverless runtimes.

The exploit sequence begins by encoding the malicious root Certificate Authority PEM block into a format suitable for URL query parameters. The sandboxed code instantiates a URLSearchParams object with this payload, then invokes getAll to retrieve the PEM block within a host-realm array. Finally, the sandboxed code invokes tls.setDefaultCACertificates, passing the retrieved array to overwrite the default trust anchor list of the process.

Upon successful execution, the entire Node.js thread or process immediately shifts to the new cryptographic trust anchors. The previous root certificates provided by the operating system or Node.js bundle are completely replaced. Any subsequent outbound connections established using standard TLS clients, including native https or library-based clients like axios that use the default CA store, will trust certificates signed by the attacker's newly injected CA.

In a typical attack scenario, the attacker pairs this trust-store manipulation with network interception techniques such as DNS spoofing or ARP poisoning. Once the host process attempts to contact an external service, the attacker intercepts the connection and supplies a certificate signed by the rogue CA. The host process accepts the certificate as valid, enabling the attacker to decrypt sensitive transaction data, steal API tokens, or inject malicious payloads into subsequent server responses.

Downstream Impact and Cryptographic Implications

The impact of process-wide TLS trust store compromise is extensive and difficult to isolate. In modern cloud environments, Node.js applications frequently interact with metadata services, database endpoints, identity providers, and API gateways. When the trust store is compromised, the confidentiality and integrity of all these channels are undermined, transforming a local sandbox escape into a broad network security failure.

Because tls.setDefaultCACertificates alters the OpenSSL configuration for the entire process, the impact is not limited to the execution context of the sandbox. Even if the sandbox is terminated or the script execution finishes, the modified CA store persists for the remaining lifecycle of the host Node.js process. Any other unrelated request handler or application module executing on the same host will use the corrupted CA store, magnifying the scope of the vulnerability.

Furthermore, detecting this mutation from application logs is challenging. Standard application monitoring tools typically log HTTP request URLs and response times, but do not inspect the details of the TLS handshake or the specific CA path used to validate a connection. This lack of visibility means that an active man-in-the-middle attack facilitated by this vulnerability can persist undetected for long periods, leading to silent, ongoing data exfiltration.

The CVSS score of 10.0 reflects this severity. The attack requires no privileges, can be executed remotely if the application evaluates untrusted scripts, and has a high impact on confidentiality and integrity. The only limitation is the availability of both tls and url modules, which are frequently allowed together due to their joint utility in processing web requests and handling callbacks.

Remediation and Patch Analysis

The vulnerability was resolved in version 3.11.7 of vm2 by implementing a defensive sanitization layer in lib/builtin.js. The maintenance team introduced a dictionary of member-level sanitizers, called BUILTIN_MEMBER_SANITIZERS. Before a permitted module is wrapped in the read-only Proxy and returned to the sandbox, it must pass through this sanitization pipeline to neutralize dangerous process-wide methods.

The specific patch for the tls module, implemented in sanitizeTlsModule, intercepts the exported object and replaces setDefaultCACertificates with a stub function. When sandboxed code attempts to call this method, the stub executes instead of the native function, throwing an error indicating that the method is disabled due to security concerns. This blocks the attack vector at the module-exposure level, ensuring the native C++ method is never reachable from the sandboxed environment.

// Neutralizing setDefaultCACertificates inside lib/builtin.js
function sanitizeTlsModule(mod) {
	if (typeof mod.setDefaultCACertificates !== 'function') return mod;
	const copy = Object.assign({}, mod);
	copy.setDefaultCACertificates = function setDefaultCACertificates() {
		throw new Error('tls.setDefaultCACertificates is disabled in vm2 sandboxes: it replaces the host process default CA trust store (GHSA-98xx-8mx4-x7cm).');
	};
	return copy;
}

While the fix is highly effective for tls.setDefaultCACertificates, blocklist-based sanitization has inherent limitations. If Node.js introduces new global configuration methods in other built-in modules, or if an existing method was overlooked, the sandbox remains potentially vulnerable. This highlights the difficulty of maintaining a secure sandbox in a complex, rapidly evolving runtime environment like Node.js, where native bindings continuously expand the attack surface.

Due to the repeated discovery of critical sandbox escape vectors, the vm2 library has been officially deprecated. The maintainers acknowledge that the architecture of wrapping Node.js APIs in ES6 Proxies cannot guarantee complete isolation against determined attackers. Organizations must migrate to robust isolation patterns, such as isolating untrusted code in separate operating system processes, micro-VMs, or WebAssembly execution environments.

Official Patches

Patrik SimekSecurity fix commit aa146a77f859325e079f3bfbfe6d8309af483daa
Patrik SimekRelease 3.11.7 containing the patch for CVE-2026-92941

Fix Analysis (1)

Technical Appendix

CVSS Score
10.0/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:L
EPSS Probability
0.29%
Top 81% most exploited

Affected Systems

Applications utilizing the vm2 Node.js library configured with a NodeVM instance that permits access to both 'tls' and 'url' built-in modules.

Affected Versions Detail

Product
Affected Versions
Fixed Version
vm2
Patrik Simek
>= 3.11.3, < 3.11.73.11.7
AttributeDetail
CWE IDCWE-732
Attack VectorNetwork / Code Execution Boundary
CVSS Score10.0
EPSS Score0.00289
ImpactProcess-Wide TLS Trust Store Compromise
Exploit Statuspoc
KEV StatusNot Listed

MITRE ATT&CK Mapping

T1222File and Directory Permissions Modification
Defense Evasion
CWE-732
Incorrect Permission Assignment for Critical Resource

The product specifies permissions for a security-critical resource in a way that allows that resource to be accessed or modified by unauthorized actors.

Known Exploits & Detection

GitHub Security AdvisoryDetailed advisory documentation including proof-of-concept explanation.

Vulnerability Timeline

Remediation code patch committed to the vm2 repository.
2026-08-22
CVE-2026-92941 published in registry.
2026-09-17
GitHub Advisory GHSA-98xx-8mx4-x7cm disclosed publicly.
2026-09-17
NVD analyzed and assigned critical CVSS score of 10.0.
2026-09-17
Vulnerability metadata populated across secondary threat vulnerability indexes.
2026-09-19

References & Sources

  • [1]CVE.org Record
  • [2]NVD Record
  • [3]GitHub Security Advisory
  • [4]Official Remediation Commit
  • [5]Official Release v3.11.7

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•2 days ago•CVE-2026-128087
3.7

CVE-2026-128087: Premature Key Exchange Callback Invocation Prior to Host Key Verification in russh

CVE-2026-128087 (GHSA-9264-jvgf-6w2f) is an incorrect behavior order (CWE-696) and improper authorization (CWE-863) vulnerability in the russh Rust SSH library, affecting versions 0.55.0 through 0.65.0. During the initial SSH key exchange (KEX) handshake, the client state machine invokes the client::Handler::kex_done() callback—providing the negotiated raw shared secret bytes—prior to validating the remote server's host key or certificate via check_server_key(). Consequently, an untrusted or rogue SSH server can complete cryptographic key agreement and force a connecting client to execute side-effecting application logic inside kex_done() before the server's identity is checked and rejected.

Amit Schendel
Amit Schendel
8 views•10 min read
•2 days ago•CVE-2026-128082
7.5

CVE-2026-128082: Uncontrolled Recursion and Denial of Service in AutoMapper via Constructor Parameter Mapping

CVE-2026-128082 (GHSA-6vhm-j9h7-f9gh) is an uncontrolled recursion vulnerability (CWE-674) in AutoMapper, a convention-based object-object mapper for .NET. When mapping nested or self-referential types into destination models that rely on parameterized constructors, C# positional records, or recursive ConstructUsing expressions, AutoMapper evaluates child constructor arguments prior to incrementing the parent's recursion depth counter. This ordering flaw bypasses both explicit MaxDepth limits and the default depth limit of 64. An unauthenticated remote attacker can supply deeply nested input payloads to affected endpoints, exhausting the thread call stack and triggering an uncatchable System.StackOverflowException that terminates the hosting .NET process.

Amit Schendel
Amit Schendel
9 views•11 min read
•2 days ago•CVE-2026-128080
5.8

CVE-2026-128080: Sensitive Query Parameter Disclosure on Incoming Server Spans in OpenTelemetry JavaScript (@opentelemetry/instrumentation-http)

An information exposure vulnerability in the @opentelemetry/instrumentation-http package for OpenTelemetry JavaScript versions 0.204.0 prior to 0.222.0 causes incoming HTTP server spans to record raw, unredacted query string parameters under the url.query attribute. While outgoing client spans applied built-in and user-configured query parameter redaction, incoming server spans bypassed this sanitization completely, resulting in the transmission of sensitive credentials such as pre-signed cloud URLs and API tokens to external observability backends.

Alon Barad
Alon Barad
7 views•10 min read
•2 days ago•CVE-2026-128089
7.5

CVE-2026-128089: Uncontrolled Resource Consumption in dnspython WKS Record Parser

CVE-2026-128089 is an uncontrolled resource consumption vulnerability in the dnspython toolkit for Python, affecting all versions prior to 2.9.2. When parsing Well-Known Service (WKS) records from text via dns.rdtypes.IN.WKS.WKS.from_text(), the parser fails to validate that numeric service port identifiers fall within the RFC 1035 valid range of 0 through 65535. An attacker capable of supplying untrusted zone files or RDATA text strings containing an arbitrarily large service port integer can force the parser to allocate an unbounded bitmap array using an inefficient linear append loop, resulting in severe CPU exhaustion, application hangs, or Out-Of-Memory (OOM) process termination.

Amit Schendel
Amit Schendel
10 views•10 min read
•2 days ago•CVE-2026-126347
3.1

CVE-2026-126347: Open Redirect via Triple-Slash Redirect Paths in Tornado RedirectHandler

CVE-2026-126347 (GHSA-5cjw-f85j-cv6r) is an open redirect vulnerability (CWE-601) in Tornado, an asynchronous Python networking library and web framework. The flaw resides in tornado.web.RedirectHandler when dynamic URL redirection templates incorporate unvalidated user input. Due to a parser differential between RFC 3986 (used by Python's urllib.parse.urlsplit) and the WHATWG URL Standard (used by modern web browsers), inputs containing three or more leading slashes bypass Tornado 6.6.0's validation logic, allowing unauthenticated attackers to redirect users to arbitrary external domains.

Alon Barad
Alon Barad
8 views•11 min read
•2 days ago•CVE-2026-128123
5.9

CVE-2026-128123: Uncaught Exception and Denial of Service in SvelteKit @sveltejs/adapter-node

A Denial of Service (DoS) vulnerability exists in @sveltejs/adapter-node versions 5.5.7 and 6.0.0-next.0 through 6.0.0. When a SvelteKit server route returns a direct response from a fetch() call with a Content-Type of text/event-stream, the Node.js adapter attempts to mutate the response headers to disable proxy buffering. Because headers returned directly by the WHATWG Fetch API carry an immutable guard, this mutation throws an unhandled TypeError, terminating the underlying Node.js process and denying service to all active and subsequent clients.

Alon Barad
Alon Barad
8 views•9 min read