Skip to content

feat: deny-by-default permission handlers on service sessions#52

Merged
devlargs merged 1 commit into
mainfrom
feat/session-permission-handler
Jul 12, 2026
Merged

feat: deny-by-default permission handlers on service sessions#52
devlargs merged 1 commit into
mainfrom
feat/session-permission-handler

Conversation

@devlargs

Copy link
Copy Markdown
Owner

Fixes #42

Service views load arbitrary third-party sites, and Electron's default grants permission requests (camera, mic, geolocation, clipboard read, ...) without prompting. This installs setPermissionRequestHandler + setPermissionCheckHandler per service session:

  • allow notifications, fullscreen, clipboard-sanitized-write everywhere
  • additionally allow media (camera/mic) on messenger.com / facebook.com / whatsapp.com so calls keep working
  • deny everything else

Handler installation is idempotent per session, so view recreation is safe. Link previews share the service partition and inherit the same policy.

Note for review: if some service legitimately needs another permission (e.g. Discord screen share), the allowlist is the single place to extend — could later become a per-service setting.

@devlargs
devlargs force-pushed the feat/session-permission-handler branch from 444320e to b7d91f0 Compare July 12, 2026 03:48
Service views load arbitrary third-party sites; Electron's default grants
permission requests (camera, mic, geolocation, clipboard read, ...)
without prompting. Install request+check handlers per service session:

- allow notifications, fullscreen, sanitized clipboard write everywhere
- additionally allow media (camera/mic) for Messenger/Facebook/WhatsApp
  hosts so calls keep working
- deny everything else

Fixes #42
@devlargs
devlargs force-pushed the feat/session-permission-handler branch from b7d91f0 to b619512 Compare July 12, 2026 03:51
@devlargs
devlargs merged commit 136bb45 into main Jul 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Security: no permission request handler on service sessions

1 participant