3.4low
Renderers can obtain access to random bluetooth device without permission in Electron
- Severity
- 3.4low CVSS:3.1 by GitHub_M
- Exploit likelihood
- 0.95% (higher than 62% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-3p22-ghq8-v749
Description
Electron is a framework for writing cross-platform desktop applications using JavaScript, HTML and CSS. A vulnerability in versions prior to `17.0.0-alpha.6`, `16.0.6`, `15.3.5`, `14.2.4`, and `13.6.6` allows renderers to obtain access to a bluetooth device via the web bluetooth API if the app has not configured a custom `select-bluetooth-device` event handler. This has been patched and Electron versions `17.0.0-alpha.6`, `16.0.6`, `15.3.5`, `14.2.4`, and `13.6.6` contain the fix. Code from the GitHub Security Advisory can be added to the app to work around the issue.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| electron electron | < 13.6.6, >= 14.0.0-beta.1, < 14.2.4, >= 15.0.0-beta.1, < 15.3.5, >= 16.0.0-beta.1, < 16.0.6, >= 17.0.0-alpha.1, <= 17.0.0-alpha.5 | CVE List |
| electron (npm) | before 13.6.6, from 14.0.0-beta.1 before 14.2.4, from 15.0.0-beta.1 before 15.3.5, from 16.0.0-beta.1 before 16.0.6, from 17.0.0-alpha.1 before 17.0.0-alpha.6 | GitHub Advisory Database |
| electronjs electron | before 13.6.6, from 14.0.0 before 14.2.4, from 15.0.0 before 15.3.5, from 16.0.0 before 16.0.6, 17.0.0 | NVD |
All scores
| GitHub_M | 3.4low CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:N/A:N |
| GitHub | 3.4low CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:N/A:N |
| NVD | 5.0medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:N/A:N |
| NVD | 4.0medium CVSS:2.0 | AV:N/AC:L/Au:S/C:P/I:N/A:N |
Classification
What each source says
CVE List
Electron is a framework for writing cross-platform desktop applications using JavaScript, HTML and CSS. A vulnerability in versions prior to `17.0.0-alpha.6`, `16.0.6`, `15.3.5`, `14.2.4`, and `13.6.6` allows renderers to obtain access to a bluetooth device via the web bluetooth API if the app has not configured a custom `select-bluetooth-device` event handler. This has been patched and Electron versions `17.0.0-alpha.6`, `16.0.6`, `15.3.5`, `14.2.4`, and `13.6.6` contain the fix. Code from the GitHub Security Advisory can be added to the app to work around the issue.
GitHub Advisory Database
Impact
This vulnerability allows renderers to obtain access to a random bluetooth device via the web bluetooth API if the app has not configured a custom select-bluetooth-device event handler. The device that is accessed is random and the attacker would have no way of selecting a specific device.
All current stable versions of Electron are affected.
Patches
This has been patched and the following Electron versions contain the fix:
17.0.0-alpha.616.0.615.3.514.2.413.6.6
Workarounds
Adding this code to your app can workaround the issue.
app.on('web-contents-created', (event, webContents) => {
webContents.on('select-bluetooth-device', (event, devices, callback) => {
// Prevent default behavior
event.preventDefault();
// Cancel the request
callback('');
});
});
For more information If you have any questions or comments about this advisory, email us at security@electronjs.org.
NVD (es)
Electron es un marco de trabajo para escribir aplicaciones de escritorio multiplataforma usando JavaScript, HTML y CSS. Una vulnerabilidad en las versiones anteriores a "17.0.0-alpha.6", "16.0.6", "15.3.5", "14.2.4" y "13.6.6" permite a renderizadores obtener acceso a un dispositivo bluetooth por medio de la API bluetooth de la web si la aplicación no ha configurado un controlador de eventos personalizado "select-bluetooth-device". Esto ha sido parcheado y las versiones de Electron "17.0.0-alpha.6", "16.0.6", "15.3.5", "14.2.4" y "13.6.6" contienen la corrección. El código del aviso de seguridad de GitHub puede añadirse a la aplicación para mitigar el problema
References
| https://github.com/electron/electron/security/advisories/GHSA-3p22-ghq8-v749 | mitigation, third-party-advisory, web | |
| https://github.com/electron/electron/pull/32178 | issue-tracking, patch, third-party-advisory, web | |
| https://github.com/electron/electron/pull/32240 | issue-tracking, patch, third-party-advisory, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2022-21718 | advisory | |
| https://github.com/electron/electron | package | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2022-21718 changed 2025-04-23 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-3p22-ghq8-v749 changed 2023-11-08 | CC-BY-4.0 |
| NVD | CVE-2022-21718 changed 2026-06-17 | Public domain |