{"id":"GHSA-r5p7-gp4j-qhrx","revision":"9ef6135df7a64efd94cd333a326f54b0","records":[{"revision":"9ef6135df7a64efd94cd333a326f54b0","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-r5p7-gp4j-qhrx","aliases":["CVE-2026-34777"],"title":"Electron: Incorrect origin passed to permission request handler for iframe requests","description":"### Impact\nWhen an iframe requests `fullscreen`, `pointerLock`, `keyboardLock`, `openExternal`, or `media` permissions, the origin passed to `session.setPermissionRequestHandler()` was the top-level page's origin rather than the requesting iframe's origin. Apps that grant permissions based on the origin parameter or `webContents.getURL()` may inadvertently grant permissions to embedded third-party content.\n\nThe correct requesting URL remains available via `details.requestingUrl`. Apps that already check `details.requestingUrl` are not affected.\n\n### Workarounds\nIn your `setPermissionRequestHandler`, inspect `details.requestingUrl` rather than the origin parameter or `webContents.getURL()` when deciding whether to grant `fullscreen`, `pointerLock`, `keyboardLock`, `openExternal`, or `media` permissions.\n\n### Fixed Versions\n* `41.0.0`\n* `40.8.1`\n* `39.8.1`\n* `38.8.6`\n\n### For more information\nIf there are any questions or comments about this advisory, please email [security@electronjs.org](mailto:security@electronjs.org)","state":0,"publishedAt":"2026-04-03T02:44:26+00:00","modifiedAt":"2026-04-06T23:18:50.776701+00:00","affected":[{"ecosystem":"npm","name":"electron","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"38.8.6"}]}],"versions":[],"rawVersionEvidence":null},{"ecosystem":"npm","name":"electron","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"39.0.0-alpha.1"},{"kind":"fixed","version":"39.8.1"}]}],"versions":[],"rawVersionEvidence":null},{"ecosystem":"npm","name":"electron","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"40.0.0-alpha.1"},{"kind":"fixed","version":"40.8.1"}]}],"versions":[],"rawVersionEvidence":null},{"ecosystem":"npm","name":"electron","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"41.0.0-alpha.1"},{"kind":"fixed","version":"41.0.0"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"MODERATE"}],"references":["https://github.com/electron/electron/security/advisories/GHSA-r5p7-gp4j-qhrx","https://nvd.nist.gov/vuln/detail/CVE-2026-34777","https://github.com/electron/electron"],"sourceUrl":"https://github.com/advisories/GHSA-r5p7-gp4j-qhrx","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-r5p7-gp4j-qhrx","identifiers":["GHSA-r5p7-gp4j-qhrx","CVE-2026-34777"]},"retained":false,"historicalAffected":[]}],"coverage":[]}