ElectronApplication · Electronjs

CVE-2026-34764

MEDIUM · 5.5 CVSS v3.1 Published 2026-04-06
Fix available
A fix is available. Upgrade to 39.8.5 / 40.8.5 or later.
See remediation →
57/100
Remediation priority · Elevated
Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
Electron is a framework for writing cross-platform desktop applications using JavaScript, HTML and CSS. From 33.0.0-alpha.1 to before 39.8.5, 40.8.5, 41.1.0, and 42.0.0-alpha.5, apps that use offscreen rendering with GPU shared textures may be vulnerable to a use-after-free. Under certain conditions, the release() callback provided on a paint event texture can outlive its backing native state, and invoking it after that point dereferences freed memory in the main process, which may lead to a crash or memory corruption. Apps are only affected if they use offscreen rendering with webPreferences.offscreen: { useSharedTexture: true }. Apps that do not enable shared-texture offscreen rendering are not affected. To mitigate this issue, ensure texture.release() is called promptly after the texture has been consumed, before the texture object becomes unreachable. This vulnerability is fixed in 39.8.5, 40.8.5, 41.1.0, and 42.0.0-alpha.5.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

Use-after-free vulnerability in Electron's offscreen rendering when using GPU shared textures. The release() callback on paint event textures can outlive its backing native state, causing dereferencing of freed memory in the main process when invoked after that point, leading to crash or memory corruption.

MitigationUpgrade Electron to version 39.8.5, 40.8.5, 41.1.0, or 42.0.0-alpha.5 or later. For apps using offscreen rendering with useSharedTexture:true, ensure texture.release() is called promptly after the texture is consumed and before the texture object becomes unreachable.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
ElectronApplication
Affected:>= 33.0.0, < 39.8.5>= 40.0.0, < 40.8.5>= 41.0.0, < 41.1.0= 42.0.0

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Local
Complexity
Low
Privileges
Low
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Check installed Electron version
    Run 'electron --version' in the application environment, or inspect the electron version in package.json, or programmatically via process.versions.electron in the running app
    Affected if version is >= 33.0.0 and < 39.8.5, OR >= 40.0.0 and < 40.8.5, OR >= 41.0.0 and < 41.1.0, OR exactly 42.0.0 (non-alpha)
  2. Verify offscreen rendering is enabled
    Search BrowserWindow creation code for webPreferences.offscreen set to true, or check if the application uses the 'offscreen' browser window flag
    Affected if offscreen rendering is enabled in any BrowserWindow configuration
  3. Confirm useSharedTexture is in use
    Search for useSharedTexture:true in BrowserWindow webPreferences, or look for session.setBackgroundThrottling calls with offscreen rendering, or inspect GPU process flags
    Affected if useSharedTexture is explicitly enabled or the app uses GPU shared textures with offscreen rendering
  4. Check for texture release callback patterns
    Search code for paint event handlers that invoke texture.release() or register release callbacks on paint event textures in offscreen rendering contexts
    Affected if the application uses release() callbacks on paint event textures with GPU shared textures enabled

The environment is affected only if running a vulnerable Electron version AND using offscreen rendering with GPU shared textures (useSharedTexture:true), where release() callbacks may outlive their backing native state.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 39.8.5 / 40.8.5 / 41.1.0 or later
Fixed in 39.8.540.8.541.1.0
Interim mitigation

Upgrade Electron to version 39.8.5, 40.8.5, 41.1.0, or 42.0.0-alpha.5 or later. For apps using offscreen rendering with useSharedTexture:true, ensure texture.release() is called promptly after the texture is consumed and before the texture object becomes unreachable.

Recommended fix High confidence

39.8.5 (for 33.x-38.x users), 40.8.5 (for 40.x users), 41.1.0 (for 41.x users), or 42.0.0+ (for 42.x users)

  1. 1. Identify the current Electron version in use by checking package.json or running 'electron --version'
  2. 2. Determine which major version line (33.x, 40.x, 41.x, or 42.x) your application is using
  3. 3. For applications on the 33.x-38.x line: upgrade to version 39.8.5 or later
  4. 4. For applications on the 40.x line: upgrade to version 40.8.5 or later
  5. 5. For applications on the 41.x line: upgrade to version 41.1.0 or later
  6. 6. For applications on the 42.x line: upgrade to version 42.0.0 or later (or 42.0.0-alpha.5 if using alpha)
  7. 7. Update the electron dependency in package.json to the appropriate fixed version
  8. 8. Run 'npm install' or 'npm update' to install the new version
Caveat No breaking changes expected; this is a security patch release. Test offscreen rendering functionality with shared textures to verify proper behavior.

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Electron Scoped from the published advisory
  • Consultation2.0 h
  • Implementation4.0 h
  • Testing4.0 h
  • Review / QA2.0 h
12.0 hours of engineering $2,080
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $3,328.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2026-34764 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2026-34764 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data