SecureEnclaveSignatureProvider
public protocol SecureEnclaveSignatureProvider
Provides access for gathering biometrics related registration and authentication data.
-
Opens a pairing session and creates a
PairingSessionobject with it. ThePairingSessionobject must be aborted withabortwhen the registration process was unsuccessfull.Throws
SecureEnclaveSignatureProviderErrorDeclaration
Swift
func createPairingSession() throws -> PairingSessionReturn Value
Instance of
PairingSession -
Creates a RegistrationData object using a
JWTSignerto sign thePairingData.Declaration
Swift
func signPairingSession(_ pairingSession: PairingSession, with signer: JWTSigner, certificate: X509) -> AnyPublisher<RegistrationData, SecureEnclaveSignatureProviderError>Parameters
pairingSessionPairingSessioninstance that is used to identify the biometric key.signerThe
JWTSignerthat is used to authenticate the key that is paired. Usually this is a eGK.certificateCertificate of the signer that is used to sign the
PairingData. -
Cancels the signing session and delete all temporary data, such as
PrK_SE_AUTandPuK_SE_AUT.Declaration
Swift
func abort(pairingSession: PairingSession) throwsParameters
pairingSessionThe
PairingSessionthat needs cancelation. -
Provides
SignedAuthenticationDataby gathering all necessary data and signing them withPrK_SE_AUT. Will automatically handle biometric unlock such as FaceID or TouchID.Declaration
Swift
func authenticationData(for challenge: IDPChallengeSession) -> AnyPublisher<SignedAuthenticationData, SecureEnclaveSignatureProviderError>Parameters
challengeThe
IDPChallengeSessionto sign withPrK_SE_AUT. -
If the Publishers value is true, biometrics is successfully registered, false otherwise.
Declaration
Swift
var isBiometrieRegistered: AnyPublisher<Bool, Never> { get }
View on GitHub
SecureEnclaveSignatureProvider Protocol Reference