WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
322092
Digital Credentials: coordinator can be left permanently in the Requesting state if the session stops during construction
https://bugs.webkit.org/show_bug.cgi?id=322092
Summary
Digital Credentials: coordinator can be left permanently in the Requesting st...
Marcos Caceres
Reported
2026-08-19 00:40:06 PDT
CredentialRequestCoordinator::prepareCredentialRequests sets the interaction state to Requesting, then creates a DigitalCredentialsSession, and only assigns m_activeSession after create() returns. DigitalCredentialsSession::create() calls suspendIfNeeded(). If the requesting context is already stopped, ScriptExecutionContext::suspendActiveDOMObjectIfNeeded calls the session's stop() during construction. stop() calls abandon(), which calls CredentialRequestCoordinator::sessionDidFinish(). That early-returns because m_activeSession does not yet point at this session, so the state is never returned to Idle. Control then returns to prepareCredentialRequests, which assigns m_activeSession to a session that has already finished. The coordinator is per-Page, so the result is that the page is left in the Requesting state permanently and every subsequent navigator.credentials.get() on it rejects with NotAllowedError for the lifetime of the page. Reachability is not established. CredentialsContainer::get rejects with InvalidStateError when the document is not fully active, before the coordinator is reached, and I could not construct a document that is stopped but still fully active. The ordering is wrong regardless of whether web content can currently reach it. Found by two independent code reviews of the change that landed as
319421@main
.
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2026-08-19 00:40:12 PDT
<
rdar://problem/185291471
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug