WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
206248
[WebAuthn] Move the async code from WebAuthenticationPanelClient to AuthenticatorManager
https://bugs.webkit.org/show_bug.cgi?id=206248
Summary
[WebAuthn] Move the async code from WebAuthenticationPanelClient to Authentic...
Jiewen Tan
Reported
2020-01-14 12:10:49 PST
Move the async code from WebAuthenticationPanelClient to AuthenticatorManager. The async code is supposed to protect the state of the authenticator manager from reentrance. It shouldn't sit at the API layer given the protection is needed for all different kinds of API.
Attachments
Patch
(19.53 KB, patch)
2020-02-07 18:00 PST
,
Jiewen Tan
no flags
Details
Formatted Diff
Diff
Patch
(19.53 KB, patch)
2020-02-10 12:01 PST
,
Jiewen Tan
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Jiewen Tan
Comment 1
2020-02-07 18:00:00 PST
Created
attachment 390156
[details]
Patch
Alex Christensen
Comment 2
2020-02-10 11:29:11 PST
Comment on
attachment 390156
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=390156&action=review
> Source/WebKit/UIProcess/WebAuthentication/AuthenticatorManager.cpp:281 > + dispatchPanelClientCall([retries, completionHandler = WTFMove(completionHandler)] (const API::WebAuthenticationPanel& panel) mutable {
If m_pendingRequestData.panel.get() returns null, this CompletionHandler will not be called. That's a problem that will cause hangs.
> Source/WebKit/UIProcess/WebAuthentication/AuthenticatorManager.cpp:289 > + responseVector.reserveCapacity(responses.size());
reserveInitialCapacity
Jiewen Tan
Comment 3
2020-02-10 11:38:41 PST
Comment on
attachment 390156
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=390156&action=review
Thanks for reviewing my patch, Alex.
>> Source/WebKit/UIProcess/WebAuthentication/AuthenticatorManager.cpp:281 >> + dispatchPanelClientCall([retries, completionHandler = WTFMove(completionHandler)] (const API::WebAuthenticationPanel& panel) mutable { > > If m_pendingRequestData.panel.get() returns null, this CompletionHandler will not be called. That's a problem that will cause hangs.
Well, the panel should always exist once the operations starts, see: handleRequest() -> runPanel() -> startDiscovery() -> operation starts if there is available authenticators. That's a simple null check. Also, there is a timer (m_requestTimeOutTimer) for every operation, therefore there should be no hangs.
>> Source/WebKit/UIProcess/WebAuthentication/AuthenticatorManager.cpp:289 >> + responseVector.reserveCapacity(responses.size()); > > reserveInitialCapacity
Fixed.
Jiewen Tan
Comment 4
2020-02-10 12:01:31 PST
Created
attachment 390277
[details]
Patch
Jiewen Tan
Comment 5
2020-02-10 18:38:32 PST
Comment on
attachment 390277
[details]
Patch Thanks Alex for r+ this patch. I don't think EWS failures are related. cq+ regardless.
WebKit Commit Bot
Comment 6
2020-02-10 19:34:53 PST
The commit-queue encountered the following flaky tests while processing
attachment 390277
[details]
: editing/spelling/spellcheck-attribute.html
bug 206178
(authors:
g.czajkowski@samsung.com
,
mark.lam@apple.com
, and
rniwa@webkit.org
) The commit-queue is continuing to process your patch.
WebKit Commit Bot
Comment 7
2020-02-10 19:35:31 PST
Comment on
attachment 390277
[details]
Patch Clearing flags on attachment: 390277 Committed
r256238
: <
https://trac.webkit.org/changeset/256238
>
WebKit Commit Bot
Comment 8
2020-02-10 19:35:33 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 9
2020-02-10 19:36:14 PST
<
rdar://problem/59335837
>
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