Skip to main content

Module browser_signin_offer

Module browser_signin_offer 

Source
Expand description

“Save to Vault?” for a sign-in a browser pane saw (SPEC_VAULT_GENERATE_CAPTURE_AND_BROWSER_SIGNINS_2026_10_28.md §5.1, §5.2).

The host hands srv the user name and password a page sent (credential.Offer); srv holds them here, in memory, for 2 minutes, never logged. When the page moves on (credential.Settled: a navigation, or the password field left the page) the pane shows the offer from its block meta OFFER_META_KEY, which holds only the exact origin and the masked user name, never page text. The person’s answer (browser.signin_offer_answer, from the window only) saves it into the tab’s profile, remembers “never for this site”, or drops it. The offer goes after 2 minutes or the next navigation, and the held pair with it.

Incognito never saves (§9.1). A step that asks only for the user name is held the same 2 minutes and joined to the password step that follows.

Structs§

Held 🔒
Identifier 🔒
Offers 🔒

Enums§

Answer 🔒
What the person answered.

Constants§

HOLD 🔒
How long a sign-in is held for the person’s answer.
OFFER_META_KEY 🔒
The block meta key the pane reads the offer from.
PER_SITE 🔒
One offer per site in this long: a page luring clicks can’t stack them up.
SETTLING 🔒
A navigation this soon after the offer showed is the same sign-in finishing (a redirect, or the field leaving and then the page moving), not the person moving on.

Statics§

OFFERS 🔒

Functions§

answer 🔒
The person answered offer id in pane block_id.
banner 🔒
What the pane shows: the exact origin and the masked user name, and whether it replaces a saved password. Never the password, never page text.
clear 🔒
clear_if_showing 🔒
Take the bar down if it shows offer id. The bar is block meta, kept across an srv restart, while the pair it offered is held only in memory: a bar whose pair has gone would otherwise stay up with buttons that do nothing.
clear_stale 🔒
Set block meta key to null on every pane that has it and isn’t in live.
decide 🔒
Whether to offer saving username and password for space: None when the person said never for the site or the Vault already holds exactly that; Some(true) when it holds another password for that user (an update).
expire_later 🔒
Drop sign-in id after after, and take its offer down if it is up.
forget_identifier_later 🔒
Drop the user name pane block_id sent alone at at, after HOLD.
keep_after_failure 🔒
An answer to held failed. The pair and its bar stay, so the person sees why and can try again, unless its two minutes ran out while the answer was tried: its expiry then found nothing to drop, and the password isn’t kept past them.
offer 🔒
The host saw a sign-in sent in pane block_id’s frame of origin: hold it until the page moves on. password is None for a step that asks only for the user name.
profile_of 🔒
The profile a pane keeps sign-ins under; None for Incognito or a pane that is gone.
register 🔒
browser.signin_offer_answer, from the window only: an agent can’t save, refuse or drop the person’s sign-in for them.
reset_bars 🔒
Clear the bars saved with every pane srv holds no sign-in for. Called when the host registers: a held sign-in never outlives srv, and a bar saved with a pane must not keep offering one.
settled 🔒
Pane block_id’s page moved on (a navigation, or the password field left the page): a held sign-in’s offer shows; one already showing goes, unless the sign-in is still finishing.
show 🔒