{"id":"CVE-2022-21718","aliases":["CVE-2022-21718","GHSA-3p22-ghq8-v749"],"related":[],"kind":"vulnerability","state":"published","title":"Renderers can obtain access to random bluetooth device without permission in Electron","summary":"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.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"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.","source":"cvelist"},{"lang":"en","text":"### Impact\nThis vulnerability allows renderers to obtain access to a random bluetooth device via the [web bluetooth API](https://developer.mozilla.org/en-US/docs/Web/API/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.\n\nAll current stable versions of Electron are affected.\n\n### Patches\nThis has been patched and the following Electron versions contain the fix:\n* `17.0.0-alpha.6`\n* `16.0.6`\n* `15.3.5`\n* `14.2.4`\n* `13.6.6`\n\n### Workarounds\nAdding this code to your app can workaround the issue.\n\n```js\napp.on('web-contents-created', (event, webContents) => {\n  webContents.on('select-bluetooth-device', (event, devices, callback) => {\n    // Prevent default behavior\n    event.preventDefault();\n    // Cancel the request\n    callback('');\n  });\n});\n```\n\nFor more information\nIf you have any questions or comments about this advisory, email us at security@electronjs.org.","format":"markdown","source":"ghsa"},{"lang":"es","text":"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","source":"nvd"}],"published":"2022-03-22T16:25:12.000Z","modified":"2026-06-17T04:26:50.913Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:N/A:N","score":3.4,"rating":"LOW"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:N/A:N","score":3.4,"rating":"LOW"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:N/A:N","score":3.4,"rating":"LOW"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:N/A:N","score":5,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:S/C:P/I:N/A:N","score":4,"rating":"MEDIUM"}],"cwes":["CWE-668","CWE-862"],"affected":[{"ranges":[{"version":"< 13.6.6","status":"affected"},{"version":">= 14.0.0-beta.1, < 14.2.4","status":"affected"},{"version":">= 15.0.0-beta.1, < 15.3.5","status":"affected"},{"version":">= 16.0.0-beta.1, < 16.0.6","status":"affected"},{"version":">= 17.0.0-alpha.1, <= 17.0.0-alpha.5","status":"affected"}],"vendor":"electron","product":"electron","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"13.6.6"}],"ecosystem":"npm","package":"electron","purl":"pkg:npm/electron","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"14.0.0-beta.1","status":"affected","fixed":"14.2.4"}],"ecosystem":"npm","package":"electron","purl":"pkg:npm/electron","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"15.0.0-beta.1","status":"affected","fixed":"15.3.5"}],"ecosystem":"npm","package":"electron","purl":"pkg:npm/electron","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"16.0.0-beta.1","status":"affected","fixed":"16.0.6"}],"ecosystem":"npm","package":"electron","purl":"pkg:npm/electron","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"17.0.0-alpha.1","status":"affected","fixed":"17.0.0-alpha.6"}],"ecosystem":"npm","package":"electron","purl":"pkg:npm/electron","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"13.6.6"},{"status":"affected","introduced":"14.0.0","fixed":"14.2.4"},{"status":"affected","introduced":"15.0.0","fixed":"15.3.5"},{"status":"affected","introduced":"16.0.0","fixed":"16.0.6"},{"status":"affected","version":"17.0.0"},{"status":"affected","version":"17.0.0"},{"status":"affected","version":"17.0.0"},{"status":"affected","version":"17.0.0"},{"status":"affected","version":"17.0.0"}],"vendor":"electronjs","product":"electron","cpe":"cpe:2.3:a:electronjs:electron:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/electron/electron/security/advisories/GHSA-3p22-ghq8-v749","tags":["mitigation","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/electron/electron/pull/32178","tags":["issue-tracking","patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/electron/electron/pull/32240","tags":["issue-tracking","patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-21718","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/electron/electron","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2025-04-23T14:08:46.712Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-21718","url":"https://www.cve.org/CVERecord?id=CVE-2022-21718","licence":"CVE Terms of Use","modified":"2025-04-23T18:45:03.237Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-3p22-ghq8-v749","url":"https://github.com/advisories/GHSA-3p22-ghq8-v749","licence":"CC-BY-4.0","modified":"2023-11-08T04:08:09.293Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-21718","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-21718","licence":"Public domain","modified":"2026-06-17T04:26:50.913Z"}],"updatedAt":"2026-11-25T22:58:10.223Z","epss":{"score":0.00946,"percentile":0.62112,"date":"2026-12-01T12:00:22.000Z"}}