Skip to main content

Module browser_permission

Module browser_permission 

Source
Expand description

A page’s camera, microphone, location or notification request in a browser pane an agent drives (docs/reports/REPORT_AGENTS_AND_OS_PROMPTS_2026_11_07.md §3 tier 1, §4). The host holds the request and asks here (/api/v1/host/browser_permission). Nothing is allowed on the agent’s word: the first ask files an os_prompt_answer request like any sensitive operation (the super agent reviews it, the person can veto its countdown), and answers pending at once, so the page’s request is denied now and the agent is told. When the countdown ends unvetoed the site holds a grant for a while, and the page’s next request is allowed without asking again.

Screen and system-audio capture are not offered: the agent would be sharing the person’s screen.

Structs§

Ask 🔒
The request an agent’s pane is waiting on: who asked, for which site and what.
Grant 🔒

Constants§

COUNTDOWN_POLL 🔒
How often the countdown of a request is looked at, and how long a request may wait for its countdown (the super agent reviews it first) before nobody is told of it any more.
COUNTDOWN_WAIT 🔒
DEVICE_AUDIO_CAPTURE 🔒
CEF’s cef_media_access_permission_types_t bits.
DEVICE_VIDEO_CAPTURE 🔒
GRANT_MS 🔒
How long an approved site stays allowed.
MAX_KEPT 🔒
Asks and grants kept: the oldest go first.
PROMPT_GEOLOCATION 🔒
CEF’s cef_permission_request_types_t bits for a permission prompt (a different list from the media bits).
PROMPT_NOTIFICATIONS 🔒

Statics§

ASKS 🔒
GRANTS 🔒

Functions§

announce_countdown 🔒
Tells the person, as a Browser ask in the pane, while the request’s countdown runs: the tone, the status bar’s list and its Browser count then say where the question is, as they do for a hand-off. It is announced for the length of the countdown, which is when the person can still veto (not after it ends, when the page is already allowed), and not while the super agent is still reviewing, which is not the person’s to answer. Ends when the countdown does, however it ends.
announce_countdown_with 🔒
asked_reason 🔒
What the agent is told when its pane’s page asked and the person is being asked.
asks 🔒
audit_standing_allow 🔒
A remembered grant covered this ask, with no fresh countdown: one Audit row for it, flagged standing (§4.6) so it reads the same as a fresh countdown’s row rather than vanishing into the per-pane notice log alone — a site allowed many times unattended should still show up. lasting says a row the person made in Settings allowed it, which has no 30 minutes to put in the answer.
covers 🔒
facts_for 🔒
The facts of the request, from what AgentMux saw: only the site is the page’s, cleaned as every fact is.
first_use_of_grant 🔒
Marks the grant that covers this ask as audited; true only the first time, so a page re-asking during its 30 minutes adds no further Audit rows.
grant_after_countdown 🔒
What the countdown ending unvetoed does: the site may use what it asked for for a while, for each agent that still asks.
grants 🔒
handle_host_browser_permission 🔒
POST /api/v1/host/browser_permission — the host holds a page’s camera, microphone, location or notification request in a pane an agent drives and asks what to do. Body {target, origin, requested, prompt} (prompt: the bits are a permission prompt’s, not a media request’s); answers allow, or deny (with the agent told why in its next Browser call). Host only.
is_granted 🔒
kinds_of 🔒
What the page asked for, in words. prompt says which list requested is from: a permission prompt (location, notifications) or a media request (camera, microphone). Anything else is refused with why.
open_ask 🔒
The open request this agent already filed for this site and these kinds, if it still waits.
remember 🔒
what_of 🔒
The kinds as the thing used, for a sentence: “the camera and the microphone”, “notifications”.