CVE-2022-36077
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 · uneditedThe Electron framework enables writing cross-platform desktop applications using JavaScript, HTML and CSS. In versions prior to 21.0.0-beta.1, 20.0.1, 19.0.11, and 18.3.7, Electron is vulnerable to Exposure of Sensitive Information. When following a redirect, Electron delays a check for redirecting to file:// URLs from other schemes. The contents of the file is not available to the renderer following the redirect, but if the redirect target is a SMB URL such as `file://some.website.com/`, then in some cases, Windows will connect to that server and attempt NTLM authentication, which can include sending hashed credentials.This issue has been patched in versions: 21.0.0-beta.1, 20.0.1, 19.0.11, and 18.3.7. Users are recommended to upgrade to the latest stable version of Electron. If upgrading isn't possible, this issue can be addressed without upgrading by preventing redirects to file:// URLs in the `WebContents.on('will-redirect')` event, for all WebContents as a workaround.
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 confidenceElectron versions prior to 21.0.0-beta.1, 20.0.1, 19.0.11, and 18.3.7 contain a vulnerability where redirect checks to file:// URLs are delayed. When a redirect targets a SMB URL like `file://some.website.com/`, Windows attempts NTLM authentication to the SMB server, potentially exposing hashed credentials to an attacker-controlled server.
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< 18.3.7>= 19.0.0, < 19.0.11>= 20.0.0, < 20.0.1= 21.0.0CVSS 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
- Network
- Complexity
- Low
- Privileges
- None
- User interaction
- Required
- Scope
- Changed
- Confidentiality
- Low
- Integrity
- Low
- Availability
- None
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
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 checksWork through these to decide whether this CVE applies to you.
-
Identify installed Electron versionCheck your package.json for the 'electron' dependency version, or run 'npm list electron' in your project directoryAffected if The version is less than 18.3.7, or falls between 19.0.0 and 19.0.11 (exclusive), between 20.0.0 and 20.0.1 (exclusive), or is exactly 21.0.0
-
Determine if application handles redirectsSearch your codebase for usage of WebContents.on('will-redirect'), webRequest.onBeforeRedirect, or similar redirect event handlersAffected if No redirect handler exists, or handlers do not inspect and block file:// URL targets before the redirect occurs
-
Verify Windows deployment targetCheck if your Electron application is packaged for Windows using electron-builder, electron-forge, or similar toolsAffected if The application runs on Windows and makes network requests that could trigger redirects to SMB URLs
-
Check for network request usageSearch your codebase for uses of loadURL, loadURLWithURL, or any code that fetches remote content (XMLHttpRequest, fetch, node-fetch) that could redirectAffected if Your application loads remote URLs that could be redirected to file:// targets
You are affected if your installed Electron version is within the vulnerable ranges AND your application runs on Windows AND handles network requests that could be redirected to file:// URLs.
Generated from the published advisory. Verify against your own configuration.
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 · scoped18.3.719.0.1120.0.1
Upgrade to the patched version (21.0.0-beta.1, 20.0.1, 19.0.11, or 18.3.7). If upgrading is not possible, prevent redirects to file:// URLs by adding a handler for the WebContents.on('will-redirect') event that blocks such redirects.
Electron 20.0.1 (or 19.0.11, 18.3.7, or latest stable)
- 1. Identify the current Electron version in your project (check package.json or npm list electron)
- 2. Update your package.json to specify a patched version: 18.3.7, 19.0.11, or 20.0.1 (or later stable release)
- 3. Run 'npm install' or 'npm update electron' to fetch the new version
- 4. Rebuild any native modules if necessary using 'electron-rebuild'
- 5. Test your application thoroughly to ensure functionality is intact
- 6. If immediate upgrade is not possible, add a 'will-redirect' event handler to prevent file:// URL redirects: webContents.on('will-redirect', (event, url) => { if (url.startsWith('file://')) event.preventDefault(); })
Generated from the published advisory — verify against the referenced sources before acting.
- Consultation2.0 h
- Implementation4.0 h
- Testing2.0 h
- Review / QA1.0 h
An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $2,560.
Scan for this in your stack
Free · runs locallyCheck whether your project pulls in CVE-2022-36077 — 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 sourcesPractitioner notes
ContributedPeer-ranked notes from engineers who’ve handled CVE-2022-36077 in production — separate from our analysis above.
The advisory tells you what broke. It rarely tells you what actually worked. If you’ve dealt with this one, that detail is what the next engineer is searching for.
- The version that genuinely resolved it — not the one the vendor claimed
- A config change or rule that shut the vector down
- A gotcha in the upgrade path that cost you an afternoon
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.
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.
- 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