-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cherry-pick 7516fcd. rdar://122350269
Reland [WebAuthn] Use AS APIs passing clientData for WebAuthn (274023@main) https://bugs.webkit.org/show_bug.cgi?id=268748 rdar://problem/122313244 Reviewed by Brent Fulgham. This got rolled out because we started generating the clientDataJSON for requests within AuthenticationServices, which isn't currently mocked for test infrastructure. To fix this we generate it within WACP manually whenever we are in a test. I've created https://bugs.webkit.org/show_bug.cgi?id=268774 to address the test development. Original change description: We need to be able to pass clientData to AS API in order to make assertions and registerations in cases where callerOrigin is not the same as the passed rp.id. This is required because of the way ClientDataJSON is validated. This change stops generating ClientDataJSON in AuthenticatorCoordinator as it's no longer possible to pass the raw bytes / hash along. Instead we construct a ASPublicKeyCredentialClientData when creating the requests for ASController and include the callerOrigin there. * Source/WebCore/Modules/webauthn/AuthenticatorCoordinator.cpp: (WebCore::AuthenticatorCoordinator::create): (WebCore::AuthenticatorCoordinator::discoverFromExternalSource): * Source/WebCore/Modules/webauthn/AuthenticatorCoordinatorClient.h: * Source/WebCore/Modules/webauthn/AuthenticatorResponse.cpp: (WebCore::AuthenticatorResponse::tryCreate): * Source/WebCore/Modules/webauthn/AuthenticatorResponseData.h: (WebCore::AuthenticatorResponseData::AuthenticatorResponseData): (WebCore::AuthenticatorResponseData::getSerializableForm const): * Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in: * Source/WebKit/UIProcess/WebAuthentication/Cocoa/AuthenticationServicesForwardDeclarations.h: * Source/WebKit/UIProcess/WebAuthentication/Cocoa/AuthenticationServicesSoftLink.h: * Source/WebKit/UIProcess/WebAuthentication/Cocoa/WebAuthenticatorCoordinatorProxy.mm: (WebKit::WebAuthenticatorCoordinatorProxy::constructASController): (WebKit::WebAuthenticatorCoordinatorProxy::requestsForRegisteration): (WebKit::WebAuthenticatorCoordinatorProxy::requestsForAssertion): (WebKit::WebAuthenticatorCoordinatorProxy::performRequest): (WebKit::configureRegistrationRequestContext): (WebKit::configureAssertionOptions): (WebKit::configurationAssertionRequestContext): (WebKit::WebAuthenticatorCoordinatorProxy::contextForRequest): * Source/WebKit/UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.cpp: (WebKit::WebAuthenticatorCoordinatorProxy::makeCredential): (WebKit::WebAuthenticatorCoordinatorProxy::getAssertion): * Source/WebKit/UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.h: * Source/WebKit/UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.messages.in: * Source/WebKit/WebProcess/WebAuthentication/WebAuthenticatorCoordinator.cpp: (WebKit::WebAuthenticatorCoordinator::makeCredential): (WebKit::WebAuthenticatorCoordinator::getAssertion): * Source/WebKit/WebProcess/WebAuthentication/WebAuthenticatorCoordinator.h: Canonical link: https://commits.webkit.org/274120@main Identifier: 273664.407@safari-7619.1.3-branch
- Loading branch information
Showing
16 changed files
with
129 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.