AuthenticationServices implements Sign in with Apple, passkeys and WebAuthn, password autofill, and credential authorization flows across iOS, macOS, tvOS, watchOS, and visionOS. You present an ASAuthorizationController to drive a request such as ASAuthorizationAppleIDRequest, ASAuthorizationPasswordRequest, or the platform public-key credential requests for registering and asserting passkeys, and receive the result as an ASAuthorizationCredential like ASAuthorizationAppleIDCredential. The ASAuthorizationAppleIDButton class provides the standard Sign in with Apple control, while ASAuthorizationAppleIDProvider and ASAuthorizationPasswordProvider create the corresponding requests. For enterprise single sign-on, the ASAuthorizationProviderExtension types let you build an authorization provider extension with its own login configuration, signing and encryption algorithms, and Kerberos mapping.
Authorization Flow 7
The controller and base request, credential, and provider types that drive a credential authorization.
- ClASAuthorizationControllermacOS 10.15+An object that presents and manages the authorization requests an app makes.
- ClASAuthorizationmacOS 10.15+An object that encapsulates a completed authorization, pairing the provider with the resulting credential.
- ClASAuthorizationRequestmacOS 10.15+An abstract base class for the authorization requests presented by a controller.
- PrASAuthorizationCredentialmacOS 10.15+A protocol adopted by the credential types returned from an authorization.
- PrASAuthorizationProvidermacOS 10.15+A protocol adopted by objects that create authorization requests.
- EnASAuthorizationResultiOS 16.4+The result of a successful authorization request.
- StASAuthorizationErrormacOS 10.15+An error type describing failures that occur during an authorization.
Sign in with Apple 7
The button, provider, request, and credential types for authenticating users with their Apple Account.
- ClASAuthorizationAppleIDButtonmacOS 10.15+A control that lets the user initiate the Sign in with Apple flow in your interface.
- ClASAuthorizationAppleIDProvidermacOS 10.15+A provider that creates requests to authenticate users with their Apple Account.
- ClASAuthorizationAppleIDRequestmacOS 10.15+A request to authenticate a user with their Apple Account, optionally requesting their name and email.
- ClASAuthorizationOpenIDRequestmacOS 10.15+A base request type for OpenID-style authorizations such as Sign in with Apple.
- ClASAuthorizationAppleIDCredentialmacOS 10.15+A credential that contains the user identifier, name, email, and identity token from Sign in with Apple.
- EnASUserDetectionStatus@enum ASUserDetectionStatus
- EnASUserAgeRangemacOS 14.0+@enum ASUserAgeRange
Passwords 3
Provider, request, and credential types for retrieving and storing saved passwords.
- ClASAuthorizationPasswordProvidermacOS 10.15+A provider that creates requests to retrieve stored passwords for the user.
- ClASAuthorizationPasswordRequestmacOS 10.15+A request to authenticate a user with a saved password from the keychain.
- ClASPasswordCredentialmacOS 10.15+A credential that contains a user name and password.
Platform Passkeys 6
Types for registering and asserting platform-bound public-key credentials backed by the device.
- ClASAuthorizationPlatformPublicKeyCredentialProvidermacOS 12.0+A provider that creates requests to register and assert platform-bound passkeys.
- ClASAuthorizationPlatformPublicKeyCredentialRegistrationRequestmacOS 12.0+A request to register a new platform passkey for the user.
- ClASAuthorizationPlatformPublicKeyCredentialRegistrationmacOS 12.0+A credential returned when a new platform passkey is registered.
- ClASAuthorizationPlatformPublicKeyCredentialAssertionRequestmacOS 12.0+A request to assert a platform passkey to sign a user in.
- ClASAuthorizationPlatformPublicKeyCredentialAssertionmacOS 12.0+A credential containing the signed assertion produced by a platform passkey during sign-in.
- ClASAuthorizationPlatformPublicKeyCredentialDescriptormacOS 12.0+A descriptor that identifies a specific platform passkey by its credential ID.
Security Key Credentials 6
Types for registering and asserting public-key credentials backed by a hardware security key.
- ClASAuthorizationSecurityKeyPublicKeyCredentialProvidermacOS 12.0+A provider that creates requests to register and assert security-key credentials.
- ClASAuthorizationSecurityKeyPublicKeyCredentialRegistrationRequestmacOS 12.0+A request to register a new credential on a hardware security key.
- ClASAuthorizationSecurityKeyPublicKeyCredentialRegistrationmacOS 12.0+A credential returned when a new security-key credential is registered.
- ClASAuthorizationSecurityKeyPublicKeyCredentialAssertionRequestmacOS 12.0+A request to assert a credential stored on a hardware security key.
- ClASAuthorizationSecurityKeyPublicKeyCredentialAssertionmacOS 12.0+A credential containing the signed assertion produced by a hardware security key.
- ClASAuthorizationSecurityKeyPublicKeyCredentialDescriptormacOS 12.0+@abstract An object to describe a credential on a security key.
Public-Key Credential Protocols 6
Protocols defining the shared shape of WebAuthn public-key registration, assertion, and descriptor types.
- PrASPublicKeyCredentialmacOS 12.0+@abstract The base protocol for all PublicKeyCredential credential types.
- PrASAuthorizationPublicKeyCredentialRegistrationmacOS 12.0+A protocol adopted by credentials returned from a public-key registration.
- PrASAuthorizationPublicKeyCredentialRegistrationRequestmacOS 12.0+A protocol adopted by requests that register a new public-key credential.
- PrASAuthorizationPublicKeyCredentialAssertionmacOS 12.0+A protocol adopted by credentials that carry a public-key assertion signature.
- PrASAuthorizationPublicKeyCredentialAssertionRequestmacOS 12.0+A protocol adopted by requests that assert a public-key credential.
- PrASAuthorizationPublicKeyCredentialDescriptormacOS 12.0+A protocol adopted by descriptors that identify a public-key credential.
Credential Parameters & Options 9
Algorithm identifiers and preference constants that configure how public-key credentials are created and verified.
- ClASAuthorizationPublicKeyCredentialParametersmacOS 12.0+A parameter that specifies a public-key algorithm acceptable for a credential.
- StASCOSEAlgorithmIdentifiermacOS 12.0+Constants identifying the COSE algorithms used to sign public-key credentials.
- StASCOSEEllipticCurveIdentifiermacOS 12.0+Constants identifying the COSE elliptic curves used for public-key credentials.
- StASAuthorizationPublicKeyCredentialUserVerificationPreferencemacOS 12.0+@abstract A string indicating a preference for whether the authenticator should attempt to verify the user, such as through a PIN or biometrics.
- StASAuthorizationPublicKeyCredentialAttestationKindmacOS 12.0+@abstract A string indicating the type of attestation the authenticator should attempt to perform.
- StASAuthorizationPublicKeyCredentialResidentKeyPreferencemacOS 12.0+@abstract A string used to indicate a preference for whether the authenticator should itself store the private key for a credential.
- EnASAuthorizationPublicKeyCredentialAttachmentmacOS 13.5+Constants that specify whether a credential is platform-bound or roaming.
- StASPublicKeyCredentialClientDataA value containing the WebAuthn client data signed during a credential operation.
- EnASPublicKeyCredentialClientDataCrossOriginValuemacOS 13.5+Constants indicating whether a credential operation was performed cross-origin.
WebAuthn Extensions 8
Input and output value types for the large-blob and PRF WebAuthn credential extensions.
- StASAuthorizationPublicKeyCredentialLargeBlobRegistrationInputInput that requests large-blob support during credential registration.
- StASAuthorizationPublicKeyCredentialLargeBlobRegistrationOutputOutput reporting whether large-blob support was granted during registration.
- StASAuthorizationPublicKeyCredentialLargeBlobAssertionInputInput that requests reading or writing the large-blob extension during an assertion.
- StASAuthorizationPublicKeyCredentialLargeBlobAssertionOutputOutput reporting the result of the large-blob extension during an assertion.
- StASAuthorizationPublicKeyCredentialPRFRegistrationInputInput that requests the PRF extension during credential registration.
- StASAuthorizationPublicKeyCredentialPRFRegistrationOutputOutput reporting whether the PRF extension is supported after registration.
- StASAuthorizationPublicKeyCredentialPRFAssertionInputThis type represents the inputs for the WebAuthentication PRF extension, when used during assertion requests.
- StASAuthorizationPublicKeyCredentialPRFAssertionOutputThe outputs of the WebAuthentication PRF extension, when requested during an assertion. This object represents one or two SymmetricKeys which are available anywhere the passkey can be used.
Web Authentication Session 6
Session types for performing browser-based OAuth-style authentication flows.
- ClASWebAuthenticationSessionmacOS 10.15+@class ASWebAuthenticationSession
- ClASWebAuthenticationSessionRequestmacOS 10.15+A request that a web browser session manager fulfills on behalf of an app.
- PrASWebAuthenticationSessionRequestDelegatemacOS 10.15+A protocol that receives lifecycle callbacks for a web authentication session request.
- ClASWebAuthenticationSessionWebBrowserSessionManagermacOS 10.15+The manager that routes web authentication session requests to the default browser.
- PrASWebAuthenticationSessionWebBrowserSessionHandlingmacOS 10.15+A protocol a browser implements to handle web authentication session requests.
- StASWebAuthenticationSessionErrormacOS 10.15+An error type describing failures during a web authentication session.
Credential Provider Extensions 11
Types for building an AutoFill credential provider extension that supplies passwords, passkeys, and codes.
- ClASCredentialProviderViewControllermacOS 11.0+The principal view controller for a credential provider AutoFill extension.
- ClASCredentialProviderExtensionContextmacOS 11.0+The context through which a credential provider extension completes or cancels a request.
- ClASCredentialServiceIdentifiermacOS 11.0+An identifier, such as a domain or URL, that scopes a credential to a service.
- ClASCredentialIdentityStoremacOS 11.0+The store that holds the credential identities your provider extension makes available for AutoFill.
- ClASCredentialIdentityStoreStatemacOS 11.0+An object that describes whether the credential identity store is enabled and accepting updates.
- PrASCredentialIdentitymacOS 14.0+@protocol ASCredentialIdentity
- PrASCredentialRequestmacOS 14.0+@protocol ASCredentialRequest
- EnASCredentialRequestTypemacOS 14.0+@enum ASCredentialRequestType
- StASCredentialIdentityStoreErrormacOS 11.0+An error type describing failures when updating the credential identity store.
- StASExtensionErrormacOS 11.0+An error type describing failures within a credential provider extension.
- StASAutoFillURLScopeThis structure represents the subset of URL components supported for the AutoFill of credentials.
Passkey Provider Credentials 10
Request, credential, and identity types a provider extension uses to register and assert passkeys.
- ClASPasskeyCredentialRequestmacOS 14.0+@class This class encapsulates a passkey assertion request made to a credential provider extension.
- ClASPasskeyCredentialRequestParametersmacOS 14.0+A class that holds various parameters related to a passkey credential request.
- ClASPasskeyCredentialIdentitymacOS 14.0+@class ASPasskeyCredentialIdentity
- ClASPasskeyRegistrationCredentialmacOS 14.0+@class This class encapsulates a passkey registration response created by a credential provider extension.
- ClASPasskeyAssertionCredentialmacOS 14.0+@class This class encapsulates a passkey assertion response created by a credential provider extension.
- EnASPasskeyCredentialExtensionInputAn enumeration of the WebAuthn extension inputs supplied for a passkey operation.
- StASPasskeyRegistrationCredentialExtensionInputInput describing the WebAuthn extensions requested during a passkey registration.
- StASPasskeyRegistrationCredentialExtensionOutputOutput reporting the WebAuthn extension results of a passkey registration.
- StASPasskeyAssertionCredentialExtensionInputInput describing the WebAuthn extensions requested during a passkey assertion.
- StASPasskeyAssertionCredentialExtensionOutputOutput reporting the WebAuthn extension results of a passkey assertion.
Password & One-Time-Code Provider Credentials 7
Request, credential, and identity types a provider extension uses for saved passwords and one-time codes.
- ClASPasswordCredentialRequestmacOS 14.0+@class This class encapsulates a password request made to a credential provider extension.
- ClASPasswordCredentialIdentitymacOS 11.0+@class ASPasswordCredentialIdentity
- ClASOneTimeCodeCredentialmacOS 15.0+A credential that supplies a one-time verification code to an app.
- ClASOneTimeCodeCredentialRequestmacOS 15.0+A request asking a provider extension to supply a one-time code.
- ClASOneTimeCodeCredentialIdentitymacOS 15.0+@class ASOneTimeCodeCredentialIdentity
- ClASDeliveredVerificationCodesManagerThis class allows interacting with one-time codes delivered to the system.
- StASVerificationCodeThis is an instance of a verification code.
Single Sign-On & Provider Extensions 19
Types for building enterprise single sign-on and authorization provider extensions.
- ClASAuthorizationSingleSignOnProvidermacOS 10.15+A provider that creates requests to perform single sign-on through an extension.
- ClASAuthorizationSingleSignOnRequestmacOS 10.15+A request to perform an enterprise single sign-on authorization.
- ClASAuthorizationSingleSignOnCredentialmacOS 10.15+A credential returned by a single sign-on authorization, including tokens and HTTP response data.
- ClASAuthorizationProviderExtensionAuthorizationRequestmacOS 10.15+A request passed to an authorization provider extension to perform a single sign-on operation.
- ClASAuthorizationProviderExtensionAuthorizationResultmacOS 12.0+The result an authorization provider extension returns after completing a request.
- ClASAuthorizationProviderExtensionLoginManagermacOS 13.0+An object that manages device and user registration for an authorization provider extension.
- ClASAuthorizationProviderExtensionLoginConfigurationmacOS 13.0+The configuration that defines how an authorization provider extension performs login.
- ClASAuthorizationProviderExtensionUserLoginConfigurationmacOS 14.0+The per-user login configuration applied within an authorization provider extension.
- ClASAuthorizationProviderExtensionKerberosMappingmacOS 13.0+A configuration that maps authorization claims to Kerberos ticket fields.
- PrASAuthorizationProviderExtensionRegistrationHandlermacOS 13.0+A protocol an authorization provider extension implements to handle device and user registration.
- StASAuthorizationProviderAuthorizationOperationmacOS 10.15+Constants identifying the operation an authorization provider extension is asked to perform.
- StASAuthorizationProviderExtensionEncryptionAlgorithmmacOS 15.0+Constants identifying the encryption algorithms an authorization provider extension supports.
- StASAuthorizationProviderExtensionSigningAlgorithmmacOS 15.0+Constants identifying the signing algorithms an authorization provider extension supports.
- StASAuthorizationProviderExtensionRequestOptionsmacOS 13.0+Options that configure how an authorization provider extension handles a request.
- StASAuthorizationProviderExtensionSupportedGrantTypesmacOS 14.0+Options describing the OAuth grant types an authorization provider extension supports.
- EnASAuthorizationProviderExtensionKeyTypemacOS 13.0+Constants identifying the key types an authorization provider extension manages.
- EnASAuthorizationProviderExtensionAuthenticationMethodmacOS 13.0+Constants identifying the authentication methods an authorization provider extension supports.
- EnASAuthorizationProviderExtensionRegistrationResultmacOS 13.0+Constants describing the outcome of an authorization provider extension registration.
- EnASAuthorizationProviderExtensionPlatformSSOProtocolVersionmacOS 14.0+Constants identifying the Platform SSO protocol version an extension uses.
Web Browser Credential Support 9
Types that let a web browser drive platform and security-key public-key credential flows on the user's behalf.
- ClASAuthorizationWebBrowserPublicKeyCredentialManagermacOS 13.3+An object that lets a browser app enumerate and manage the user's platform passkeys.
- StASAuthorizationWebBrowserPlatformPublicKeyCredentialA value describing a platform passkey that a browser can present to the user.
- PrASAuthorizationWebBrowserPlatformPublicKeyCredentialProviderA protocol adopted by providers that create browser-driven platform passkey requests.
- PrASAuthorizationWebBrowserSecurityKeyPublicKeyCredentialProviderA protocol adopted by providers that create browser-driven security-key requests.
- PrASAuthorizationWebBrowserExternallyAuthenticatableRequestmacOS 13.3+A protocol for requests a browser can authenticate using an externally provided assertion.
- PrASAuthorizationWebBrowserPlatformPublicKeyCredentialAssertionRequestmacOS 13.5+A protocol for browser-driven platform passkey assertion requests.
- PrASAuthorizationWebBrowserPlatformPublicKeyCredentialRegistrationRequestmacOS 13.5+A protocol for browser-driven platform passkey registration requests.
- PrASAuthorizationWebBrowserSecurityKeyPublicKeyCredentialAssertionRequestmacOS 14.4+A protocol for browser-driven security-key assertion requests.
- PrASAuthorizationWebBrowserSecurityKeyPublicKeyCredentialRegistrationRequestmacOS 14.4+A protocol for browser-driven security-key registration requests.
Credential Import & Export 14
Types for exchanging credentials between password managers through the standard import and export format.
- ClASCredentialExportManagerAn object that exports the user's credentials in the standard interchange format.
- ClASCredentialImportManagerAn object that imports credentials from another password manager.
- StASExportedCredentialDataA wrapper object for multiple ASImportableAccount objects
- StASImportableItemA representation of Item as defined in the [Credential Exchange Format (CXF) specs](https://fidoalliance.org/specs/cx/cxf-v1.0-rd-20250313.html)
- StASImportableLinkedItemA representation of LinkedItem as defined in the [Credential Exchange Format (CXF) specs](https://fidoalliance.org/specs/cx/cxf-v1.0-rd-20250313.html)
- StASImportableAccountA representation of Account as defined in the [Credential Exchange Format (CXF) specs](https://fidoalliance.org/specs/cx/cxf-v1.0-rd-20250313.html)
- StASImportableCollectionA representation of Collection as defined in the [Credential Exchange Format (CXF) specs](https://fidoalliance.org/specs/cx/cxf-v1.0-rd-20250313.html)
- EnASImportableCredentialA representation of Credential as defined in the [Credential Exchange Format (CXF) specs](https://fidoalliance.org/specs/cx/cxf-v1.0-rd-20250313.html)
- StASImportableCredentialScopeThe scope for where a credential should be usable.
- StASImportableEditableFieldA representation of EditableField as defined in the [Credential Exchange Format (CXF) specs](https://fidoalliance.org/specs/cx/cxf-v1.0-rd-20250313.html)
- EnASImportableExtensionA representation of CXF extensions.
- StASImportableFIDO2ExtensionsA representation of FIDO2 extensions as defined in CXF.
- StASImportableFIDO2HMACCredentialA representation of FIDO2 HMAC Credentials as defined in CXF.
- StASImportableFIDO2LargeBlobA representation of FIDO2 LargeBlob extensions as defined in CXF.
Credential Identifiers & Management 7
Identifier value types and managers for keeping stored credentials current.
- ClASCredentialDataManagerThis class allows submitting credentials and events to any credential manager enabled on the system.
- ClASCredentialUpdaterThis class allows passing update events to credential managers enabled on the system. When a user makes a change to how they sign in to an account, such as removing a credential or renaming the accoun
- StASEmailIdentifierA value that identifies a credential by an email address.
- StASPhoneNumberIdentifierA value that identifies a credential by a phone number.
- EnASContactIdentifierA value that identifies a credential by a contact such as an email or phone number.
- EnASContactIdentifierRequestA request describing the contact identifier a provider extension should match.
- ClASSettingsHelpermacOS 14.0+A helper class to provide static utility methods for quick access to settings related to credential providers.
Classes 3
- ClASAuthorizationAccountCreationPlatformPublicKeyCredential
- ClASAuthorizationAccountCreationPlatformPublicKeyCredentialRequest
- ClASAuthorizationAccountCreationProvider
Structures 5
- StAuthorizationControlleriOS 16.4+A value provided in the SwiftUI environment that views can use
- StCredentialDataManager
- StDeliveredVerificationCodesManager
- StSignInWithAppleButtoniOS 14.0+A control you add to your interface that enables users to initiate
- StWebAuthenticationSessioniOS 16.4+A value provided in the SwiftUI environment that views can use to
Protocols 4
- PrASAuthorizationControllerDelegatemacOS 10.15+
- PrASAuthorizationControllerPresentationContextProvidingmacOS 10.15+
- PrASAuthorizationProviderExtensionAuthorizationRequestHandlermacOS 10.15+
- PrASWebAuthenticationPresentationContextProvidingmacOS 10.15+@abstract Provides context to target where in an application's UI the authorization view should be shown.
Type Aliases 1
- TyASPresentationAnchor