CVE-2026-34774: Electron: Use-after-free in offscreen child window paint callback
Electron is a framework for writing cross-platform desktop applications using JavaScript, HTML and CSS. Prior to versions 39.8.1, 40.7.0, and 41.0.0, apps that use offscreen rendering and allow child windows via window.open() may be vulnerable to a use-after-free. If the parent offscreen WebContents is destroyed while a child window remains open, subsequent paint frames on the child dereference freed memory, which may lead to a crash or memory corruption. Apps are only affected if they use offscreen rendering (webPreferences.offscreen: true) and their setWindowOpenHandler permits child windows. Apps that do not use offscreen rendering, or that deny child windows, are not affected. This issue has been patched in versions 39.8.1, 40.7.0, and 41.0.0.
Security readout for executives and security teams
Plain-English summary
This is a high-severity Electron memory-safety flaw, but only in a narrow application pattern. An affected desktop app must use offscreen rendering and also allow child windows. If triggered, the app may crash or suffer memory corruption, which can threaten confidentiality, integrity, and availability.
Executive priority
Treat as high priority for Electron-based desktop products that use offscreen rendering or display remote content. The affected configuration is specific, so teams should first confirm exposure, then upgrade or disable the risky window behavior promptly.
Technical view
Before Electron 39.8.1, 40.7.0, and 41.0.0, destroying a parent offscreen WebContents while a permitted child window remains open can cause child paint callbacks to dereference freed memory. The issue is mapped to CWE-416 and CWE-825 with CVSS 3.1 score 8.1 and high confidentiality, integrity, and availability impact.
Likely exposure
Exposure is limited to Electron applications using webPreferences.offscreen: true and a setWindowOpenHandler policy that permits child windows through window.open(). Apps without offscreen rendering, or apps that deny child windows, are stated as not affected.
Exploitation context
The provided sources do not show known active exploitation, and KEV status is false. The CVSS vector indicates network attack surface, no privileges, no user interaction, but high attack complexity. Public evidence here supports risk prioritization, not a claim of exploitation in the wild.
Researcher notes
The vulnerable condition depends on lifecycle ordering between an offscreen parent WebContents and remaining child windows. Avoid assuming all Electron apps are affected. Source evidence does not identify exploit availability, real-world abuse, or affected downstream applications beyond Electron itself.
Mitigation direction
Upgrade Electron to 39.8.1, 40.7.0, 41.0.0, or later as applicable.
Disable offscreen rendering where it is not required.
Deny child windows via setWindowOpenHandler unless the app has a clear need.
Review Electron vendor guidance for any downstream framework or packaging implications.
Prioritize apps that render untrusted or remote content in Electron.
Validation and detection
Inventory Electron applications and record their embedded Electron versions.
Check BrowserWindow webPreferences for offscreen: true.
Review setWindowOpenHandler behavior for permitted child windows.
Confirm updated builds include Electron 39.8.1, 40.7.0, 41.0.0, or later.
Document non-exposure when offscreen rendering or child windows are absent.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-416: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
2CVSS vectors
5Timeline events
2ADP providers
5Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: noTechnical Impact: total
CVSS vector scores
2 official scores
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-416 · source CWE mapping
Use After Free
Use After Free represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.
Expired Pointer Dereference represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.