BiometricPrompt.CryptoObject

class BiometricPrompt.CryptoObject


A wrapper class for the crypto objects supported by BiometricPrompt.

Summary

Public constructors

Creates a crypto object that wraps the given cipher object.

@RequiresApi(value = Build.VERSION_CODES.R)
CryptoObject(identityCredential: IdentityCredential)

Creates a crypto object that wraps the given identity credential object.

Creates a crypto object that wraps the given MAC object.

@RequiresApi(value = Build.VERSION_CODES.TIRAMISU)
CryptoObject(presentationSession: PresentationSession)

Creates a crypto object that wraps the given presentation session object.

CryptoObject(signature: Signature)

Creates a crypto object that wraps the given signature object.

Public functions

Cipher?

Gets the cipher object associated with this crypto object.

IdentityCredential?
@RequiresApi(value = Build.VERSION_CODES.R)
getIdentityCredential()

Gets the identity credential object associated with this crypto object.

Mac?

Gets the MAC object associated with this crypto object.

PresentationSession?
@RequiresApi(value = Build.VERSION_CODES.TIRAMISU)
getPresentationSession()

Gets the presentation session object associated with this crypto object.

Signature?

Gets the signature object associated with this crypto object.

Public constructors

CryptoObject

Added in 1.0.0
CryptoObject(cipher: Cipher)

Creates a crypto object that wraps the given cipher object.

Parameters
cipher: Cipher

The cipher to be associated with this crypto object.

CryptoObject

Added in 1.1.0
@RequiresApi(value = Build.VERSION_CODES.R)
CryptoObject(identityCredential: IdentityCredential)

Creates a crypto object that wraps the given identity credential object.

Parameters
identityCredential: IdentityCredential

The identity credential to be associated with this crypto object.

CryptoObject

Added in 1.0.0
CryptoObject(mac: Mac)

Creates a crypto object that wraps the given MAC object.

Parameters
mac: Mac

The MAC to be associated with this crypto object.

CryptoObject

Added in 1.2.0-alpha06
@RequiresApi(value = Build.VERSION_CODES.TIRAMISU)
CryptoObject(presentationSession: PresentationSession)

Creates a crypto object that wraps the given presentation session object.

Parameters
presentationSession: PresentationSession

The presentation session to be associated with this crypto object.

CryptoObject

Added in 1.0.0
CryptoObject(signature: Signature)

Creates a crypto object that wraps the given signature object.

Parameters
signature: Signature

The signature to be associated with this crypto object.

Public functions

getCipher

Added in 1.0.0
fun getCipher(): Cipher?

Gets the cipher object associated with this crypto object.

Returns
Cipher?

The cipher, or null if none is associated with this object.

getIdentityCredential

Added in 1.1.0
@RequiresApi(value = Build.VERSION_CODES.R)
fun getIdentityCredential(): IdentityCredential?

Gets the identity credential object associated with this crypto object.

Returns
IdentityCredential?

The identity credential, or null if none is associated with this object.

getMac

Added in 1.0.0
fun getMac(): Mac?

Gets the MAC object associated with this crypto object.

Returns
Mac?

The MAC, or null if none is associated with this object.

getPresentationSession

Added in 1.2.0-alpha06
@RequiresApi(value = Build.VERSION_CODES.TIRAMISU)
fun getPresentationSession(): PresentationSession?

Gets the presentation session object associated with this crypto object.

Returns
PresentationSession?

The presentation session, or null if none is associated with this object.

getSignature

Added in 1.0.0
fun getSignature(): Signature?

Gets the signature object associated with this crypto object.

Returns
Signature?

The signature, or null if none is associated with this object.