Autofill Passkey

Hello, I used the new "Autofill Passkey" feature in my app, and all the registration steps were done well, Finally credential is registered in WebAuthn. But the problem is that when I tap on the "GetAssertion" button, instead of showing my autofill extension UI, a QR code is displayed and the function "prepareInterfaceToProvideCredentialForRequest" is not called. what is the problem? (The app is installed on the iPhone with iOS 17)

I can't tell from your question whether you're trying to support passkey sign-in or become a passkey provider, so just to make sure we're talking about the same thing 🙂: if all you want is to support passkey sign-in for your service, there's no need to implement a Credential Provider Extension. The extension is only if you plan to be a full passkey manager for all apps/websites.

If what you want is indeed to become a passkey manager, it sounds like you're likely not calling saveCredentialIdentities(_:) after registering the passkey. That lets us know what passkeys you have available. If we don't know about any passkeys on the device, we'll jump straight to the QR code.

Thank you @garrett-davidson The problem is exactly about adding the identities to the** ASCredentialIdentityStore** and now the problem is solved.

We are trying to support Passkey Management in our app with the latest iOS 17 Passkey Autofill.

During this process, we have a few doubts and queries:

  1. First, we have configured the AutoFill extension for external passkey management
  2. Next we used the 'prepareInterface(forPasskeyRegistration:' delegate for passkey generation
  3. We are facing an issue on creating the attestationObject for ‘ASPasskeyRegistrationCredential’. Here, we’re not sure if we need to create the attestationObject [if so any documentation or help regarding this] or is there any API to get the attestationObject which we are missing.
override func prepareInterface(forPasskeyRegistration registrationRequest: ASCredentialRequest) {
        
        let request = registrationRequest as! ASPasskeyCredentialRequest

        let passkeyRegistration = ASPasskeyRegistrationCredential(relyingParty: 
request.credentialIdentity.serviceIdentifier.identifier, clientDataHash: request.clientDataHash, credentialID: Data(UUID().uuidString.utf8), attestationObject: "????") 

        extensionContext.completeRegistrationRequest(using: passkeyRegistration)
    }

@Jafar96

@Sathish95 You should read the ** FIDO** and Webauthn documentation.

https://fidoalliance.org/specs/fido-v2.0-rd-20180702/fido-client-to-authenticator-protocol-v2.0-rd-20180702.html#authenticatorMakeCredential https://www.w3.org/TR/webauthn/#attestation-objects

Autofill Passkey
 
 
Q