Electron · Electron · CVE-2022-36077
**Name of the Vulnerable Software and Affected Versions**
Electron versions prior to 21.0.0-beta.1
Electron versions prior to 20.0.1
Electron versions prior to 19.0.11
Electron versions prior to 18.3.7
**Description**
The Electron framework is vulnerable to Exposure of Sensitive Information. When following a redirect, Electron delays a check for redirecting to file:// URLs from other schemes. If the redirect target is a SMB URL, such as `file://some.website.com/`, Windows may connect to that server and attempt NTLM authentication, which can include sending hashed credentials.
**Recommendations**
For versions prior to 21.0.0-beta.1, upgrade to version 21.0.0-beta.1 or later.
For versions prior to 20.0.1, upgrade to version 20.0.1 or later.
For versions prior to 19.0.11, upgrade to version 19.0.11 or later.
For versions prior to 18.3.7, upgrade to version 18.3.7 or later.
As a temporary workaround, prevent redirects to file:// URLs in the `WebContents.on('will-redirect')` event for all WebContents. This can be achieved by adding an event listener to the `web-contents-created` event and checking the URL in the `will-redirect` event. If the URL starts with `file://`, prevent the default behavior.