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-70611

CVE-2026-70611: Sandbox Escape and Command Execution via DevTools Shell Integration in Electron

Alon Barad
Alon Barad
Software Engineer

Aug 5, 2026·6 min read·81 visits

Executive Summary (TL;DR)

Unsanitized file paths sent via DevTools IPC to the main process can trigger arbitrary code execution by exploiting OS shell file launching handlers.

A high-severity sandbox escape and arbitrary command execution vulnerability exists in the Electron desktop framework prior to versions 39.8.9, 40.9.2, 41.2.1, and 42.0.0-beta.3. The flaw lies in the handling of DevTools embedder messages during file manager reveal actions, allowing an attacker to execute arbitrary binaries with main process privileges.

Vulnerability Overview

The Electron desktop application framework combines Chromium and Node.js, allowing developers to build desktop applications using web technologies. To facilitate debugging and web inspection, Electron incorporates the Chromium DevTools interface. This interface interacts with the browser's main process via specialized IPC messages handled by the DevTools embedder.\n\nThe vulnerability, tracked as CVE-2026-70611, exists in the DevTools embedder message handler for the 'reveal in file manager' action, specifically within the showItemInFolder routine. Under normal conditions, this handler is meant to open the parent directory of a file and highlight it in the system file explorer.\n\nIf an attacker can execute arbitrary JavaScript within the context of the DevTools frontend, they can invoke this message handler with an arbitrary file path. Due to insufficient sanitization, the handler can be manipulated to execute arbitrary executable files on the local host. This execution occurs with the privileges of the main process, entirely bypassing the Chromium renderer sandbox.

Root Cause Analysis

The root cause of this vulnerability lies in a structural design flaw within the InspectableWebContents::ShowItemInFolder method. When a request to highlight an item is received, the system extracts the directory portion of the path using the DirName() method of base::FilePath. It then attempts to open the directory first using platform_util::OpenPath, which subsequently completes and invokes platform_util::ShowItemInFolder.\n\nBecause the input path is entirely user-controlled, an attacker can append a dummy path component to a target executable file path. For example, a Unix path such as /bin/sh/dummy_component yields /bin/sh when evaluated by DirName(). Similarly, on Windows, C:\\Windows\\System32\\cmd.exe\\dummy_component yields C:\\Windows\\System32\\cmd.exe when the trailing component is stripped.\n\nThe resulting path is subsequently passed directly to platform_util::OpenPath. Instead of opening a folder, this function relies on operating system shell handlers, such as ShellExecute on Windows or xdg-open on Linux, to process the path. When an executable path is passed to these handlers instead of a directory path, the operating system launches the binary as a new process.\n\nmermaid\ngraph LR\n A["Attacker Input Path"] --> B["base::FilePath::DirName()"]\n B --> C["Extracted Executable Path"]\n C --> D["platform_util::OpenPath()"]\n D --> E["Operating System Shell"]\n E --> F["Arbitrary Process Execution"]\n

Code Analysis and Vulnerability Patch

A direct comparison of the vulnerable and patched code reveals how the logic was refactored to eliminate the command execution vector. In vulnerable versions of Electron, the handler was structured as follows within shell/browser/ui/inspectable_web_contents.cc:\n\ncpp\n// Vulnerable Implementation\nvoid InspectableWebContents::ShowItemInFolder(\n const std::string& file_system_path) {\n if (!pref_service_)\n return;\n\n base::FilePath path = base::FilePath::FromUTF8Unsafe(file_system_path);\n // VULNERABLE: Invokes platform_util::OpenPath on the parent directory path\n // If path is an executable with a dummy file suffix, this runs the executable\n platform_util::OpenPath(path.DirName(),\n base::BindOnce(&OnOpenItemComplete, path));\n}\n\n\nThe corresponding patch removes the call to platform_util::OpenPath and implements strict validation against the configured DevTools workspaces before calling platform_util::ShowItemInFolder directly:\n\ncpp\n// Patched Implementation\nvoid InspectableWebContents::ShowItemInFolder(\n const std::string& file_system_path) {\n if (!pref_service_)\n return;\n \n base::FilePath path = base::FilePath::FromUTF8Unsafe(file_system_path);\n\n // Only reveal paths that fall under a DevTools workspace folder the user has\n // explicitly added. The DevTools frontend is renderer-hosted and may be\n // attacker-controlled, so it must not be able to point this at arbitrary\n // filesystem locations.\n const base::Value::Dict& added_paths =\n pref_service_->GetDict(prefs::kDevToolsFileSystemPaths);\n const bool under_registered_root =\n std::ranges::any_of(added_paths, [&path](const auto& entry) {\n const base::FilePath root = base::FilePath::FromUTF8Unsafe(entry.first);\n return root == path || root.IsParent(path);\n });\n if (!under_registered_root)\n return;\n\n // FIX: Bypasses platform_util::OpenPath entirely and directly reveals the file\n platform_util::ShowItemInFolder(path);\n}\n\n\nBy replacing the indirect open-then-reveal logic with a direct invocation of ShowItemInFolder, the application ensures that the operating system only highlights the file inside the file explorer rather than executing it. Furthermore, limiting path execution to pre-registered workspace roots prevents arbitrary path traversal attacks.

Exploitation Methodology

To exploit this vulnerability, an attacker must first establish a vector to run arbitrary JavaScript within the DevTools frontend context. This requirement constitutes a significant operational barrier, raising the attack complexity. Common vectors include exploiting cross-site scripting (XSS) in an application webview where DevTools is programmatically exposed, or tricking a user into installing a malicious DevTools extension.\n\nOnce JavaScript execution within the DevTools context is achieved, the attacker interacts directly with the DevToolsAPI global object. This object exposes the IPC messaging framework of the renderer process, allowing direct communication with the host system's main process.\n\nThe attacker crafts a payload path pointing to a local executable binary. The path must include a trailing dummy component to exploit the DirName() parsing behavior. The following proof-of-concept script demonstrates how to trigger the vulnerability on both Windows and Unix-like operating systems:\n\njavascript\n// Construct the path targeting system binaries with a dummy suffix\nconst windowsTarget = "C:\\\\Windows\\\\System32\\\\cmd.exe\\\\dummy_file";\nconst unixTarget = "/bin/ls/dummy_file";\n\nconst payload = (navigator.platform.indexOf('Win') !== -1) ? windowsTarget : unixTarget;\n\n// Trigger the vulnerable handler by passing the crafted path via IPC\nif (typeof DevToolsAPI !== "undefined") {\n DevToolsAPI.sendMessageToEmbedder('showItemInFolder', [payload], null);\n}\n\n\nWhen the main process receives the IPC message, it processes the payload, trims the dummy segment, and runs the targeted executable outside the sandbox environment with host privileges.

Impact Assessment

The impact of CVE-2026-70611 is classified as high-severity because it facilitates a complete sandbox escape. Although Chromium utilizes a robust multi-process architecture to isolate untrusted web content within restricted renderer processes, this flaw bypasses those protections. Successfully executing code via the DevTools embedder grants the attacker the execution privileges of the host desktop application.\n\nDepending on the privileges under which the parent Electron application is running, the spawned executable runs with identical rights. On systems where the application is run with administrative or elevated privileges, the attacker gains full administrative control over the host operating system. This allows for unauthorized file system read/write operations, credential extraction, and persistent malware installation.\n\nThe vulnerability is assigned a CVSS v3.1 score of 6.9, reflecting the high complexity of obtaining initial execution within the DevTools context. However, in scenarios where applications expose DevTools interfaces to untrusted external remote content, the vulnerability effectively acts as a reliable direct-to-host execution bridge.

Remediation and Mitigation

The primary remediation for CVE-2026-70611 is upgrading the Electron framework to a patched release. Development teams must update their project dependencies immediately to the safe versions corresponding to their active release branches. The patched versions are 39.8.9, 40.9.2, 41.2.1, and 42.0.0-beta.3.\n\nIf upgrading the framework is not immediately viable, developers can implement defensive configurations to mitigate risk. The most effective mitigation is ensuring that DevTools is strictly disabled in production builds. This can be accomplished by intercepting keyboard shortcuts and menu items that trigger the inspector interface:\n\njavascript\n// Mitigation: Disable DevTools shortcuts in production\nconst { app, BrowserWindow } = require('electron');\n\napp.on('browser-window-created', (event, window) => {\n window.webContents.on('before-input-event', (inputEvent, input) => {\n const isDevToolsShortcut = input.key === 'F12' || \n ((input.control || input.meta) && input.shift && input.key.toLowerCase() === 'i');\n if (isDevToolsShortcut) {\n inputEvent.preventDefault();\n }\n });\n});\n\n\nAdditionally, applications must enforce strict security settings. This includes enabling contextIsolation and sandbox options, while disabling nodeIntegration in all webPreferences configurations. Security teams should also monitor system process logs for anomalous process creations where command interpreters or shell binaries are spawned directly by the primary Electron application process.

Fix Analysis (4)

Technical Appendix

CVSS Score
6.9/ 10
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:H/I:H/A:N

Affected Systems

Electron desktop applications running on WindowsElectron desktop applications running on macOSElectron desktop applications running on Linux

Affected Versions Detail

Product
Affected Versions
Fixed Version
Electron
Electron
< 39.8.939.8.9
Electron
Electron
>= 40.0.0-alpha.1, < 40.9.240.9.2
Electron
Electron
>= 41.0.0-alpha.1, < 41.2.141.2.1
Electron
Electron
>= 42.0.0-alpha.1, < 42.0.0-beta.342.0.0-beta.3
AttributeDetail
CWE IDCWE-78
Attack VectorLocal (AV:L)
CVSS Score6.9
EPSS ScoreNot Available
ImpactSandbox Escape & Arbitrary Code Execution
Exploit StatusProof-of-Concept (PoC) documented
KEV StatusNot Listed

MITRE ATT&CK Mapping

T1059Command and Scripting Interpreter
Execution
T1190Exploit Public-Facing Application
Initial Access
CWE-78
Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')

The application constructs an OS command using externally-influenced input, but it does not neutralize or incorrectly neutralizes special elements that can modify the intended command.

Known Exploits & Detection

GitHub AdvisoryOfficial advisory detailing the security flaw and containing references to vulnerability parameters.

Vulnerability Timeline

Vulnerability Fixed in Repositories
2026-04-11
Vulnerability Advisory Published
2026-08-05
NVD Record Modified
2026-08-05

References & Sources

  • [1]Electron Security Advisory GHSA-f2r8-jv7c-xqmp
  • [2]Fix Commit 10fb5b39c5287f70c4bbcab4c24197f3871ec322
  • [3]Fix Commit 1b8a298d629d5a642c816ea5f7505359de17b771
  • [4]Fix Commit 27bf1cae9274d5025684c7268496f435b7e06b44
  • [5]Fix Commit 7a1eb7e5585991b3726cedb890a6244f327f43de
  • [6]Pull Request 50937
  • [7]Pull Request 50938
  • [8]Pull Request 51114
  • [9]Pull Request 51115
  • [10]Electron Release v39.8.9
  • [11]Electron Release v40.9.2
  • [12]Electron Release v41.2.1
  • [13]Electron Release v42.0.0-beta.3

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

•21 minutes ago•CVE-2026-106121
4.9

CVE-2026-106121: Denial of Service via Infinite Loop in RabbitMQ Java Client JSON Parser

CVE-2026-106121 is a Denial of Service (DoS) vulnerability in the RabbitMQ Java Client library (amqp-client) affecting versions prior to 5.37.0. The vulnerability resides in the legacy, custom JSON-RPC parsing class com.rabbitmq.tools.json.JSONReader. When parsing malformed or truncated payloads ending within a quoted string or single-line comment, the parser's scanner enters an infinite loop. This occurs because the loop lacks an exit condition for the end-of-input sentinel character returned by the iterator, leading to either CPU exhaustion or a JVM crash from an OutOfMemoryError.

Amit Schendel
Amit Schendel
2 views•6 min read
•about 2 hours ago•CVE-2026-105646
4.9

CVE-2026-105646: Regular Expression Denial of Service in Ghost CMS Import Handlers

An authenticated Regular Expression Denial of Service (ReDoS) vulnerability in TryGhost Ghost (CMS) versions 4.0.0 through 6.66.x. An attacker with administrator privileges can upload crafted content import archives containing pathological directory names or migration patterns, triggering exponential backtracking in the Node.js V8 engine.

Alon Barad
Alon Barad
5 views•6 min read
•about 3 hours ago•CVE-2026-105645
4.9

CVE-2026-105645: Regular Expression Denial of Service (ReDoS) in Ghost CMS

CVE-2026-105645 is a regular expression denial of service (ReDoS) vulnerability affecting Ghost, an open-source Node.js content management system. The vulnerability exists within directory import handlers and the external media inliner, allowing authenticated administrators to trigger catastrophic backtracking in the V8 JavaScript engine, resulting in infinite loops, 100% CPU utilization, and total denial of service.

Amit Schendel
Amit Schendel
8 views•6 min read
•about 4 hours ago•CVE-2026-105644
6.8

CVE-2026-105644: Stored Cross-Site Scripting via Malicious SVG Content Import in Ghost CMS

A Stored Cross-Site Scripting (XSS) and Unrestricted Upload of File with Dangerous Type vulnerability in Ghost CMS (versions 4.0.0 to 6.66.x) allows remote attackers to execute arbitrary JavaScript in the context of an administrator's session. The flaw lies in the content import subsystem, which extracted and stored SVG files without sanitization or binary verification.

Amit Schendel
Amit Schendel
7 views•6 min read
•about 5 hours ago•CVE-2026-105643
7.3

CVE-2026-105643: Stored Cross-Site Scripting and Isolation Bypass in Ghost CMS

Stored Cross-Site Scripting (XSS) and origin isolation bypass vulnerability in Ghost CMS versions 6.34.0 through 6.66.1 allows low-privileged staff users to execute arbitrary JavaScript in the context of an administrator session via crafted embed cards.

Alon Barad
Alon Barad
9 views•6 min read
•about 6 hours ago•CVE-2026-105642
8.8

CVE-2026-105642: Remote Code Execution in Ghost CMS via Unsafe SVG Processing during Metadata Scraping

CVE-2026-105642 is a critical remote code execution vulnerability in Ghost CMS, affecting versions 6.56.0 through 6.66.0. The flaw resides in how Ghost's backend handles external image metadata when generating 'Bookmark' cards in the post editor. When a low-privileged staff member inputs a malicious URL, the server fetches and processes an SVG containing an embedded payload, leading to command execution via the underlying, vulnerable image-processing component.

Amit Schendel
Amit Schendel
7 views•6 min read