BiometricPrompt.CryptoObject

public 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(@NonNull 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(@NonNull PresentationSession presentationSession)

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

Creates a crypto object that wraps the given signature object.

Public methods

@Nullable Cipher

Gets the cipher object associated with this crypto object.

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

Gets the identity credential object associated with this crypto object.

@Nullable Mac

Gets the MAC object associated with this crypto object.

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

Gets the presentation session object associated with this crypto object.

@Nullable Signature

Gets the signature object associated with this crypto object.

Public constructors

CryptoObject

Added in 1.0.0
public CryptoObject(@NonNull Cipher cipher)

Creates a crypto object that wraps the given cipher object.

Parameters
@NonNull Cipher cipher

The cipher to be associated with this crypto object.

CryptoObject

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

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

Parameters
@NonNull IdentityCredential identityCredential

The identity credential to be associated with this crypto object.

CryptoObject

Added in 1.0.0
public CryptoObject(@NonNull Mac mac)

Creates a crypto object that wraps the given MAC object.

Parameters
@NonNull Mac mac

The MAC to be associated with this crypto object.

CryptoObject

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

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

Parameters
@NonNull PresentationSession presentationSession

The presentation session to be associated with this crypto object.

CryptoObject

Added in 1.0.0
public CryptoObject(@NonNull Signature signature)

Creates a crypto object that wraps the given signature object.

Parameters
@NonNull Signature signature

The signature to be associated with this crypto object.

Public methods

getCipher

Added in 1.0.0
public @Nullable Cipher getCipher()

Gets the cipher object associated with this crypto object.

Returns
@Nullable Cipher

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

getIdentityCredential

Added in 1.1.0
@RequiresApi(value = Build.VERSION_CODES.R)
public @Nullable IdentityCredential getIdentityCredential()

Gets the identity credential object associated with this crypto object.

Returns
@Nullable IdentityCredential

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

getMac

Added in 1.0.0
public @Nullable Mac getMac()

Gets the MAC object associated with this crypto object.

Returns
@Nullable 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)
public @Nullable PresentationSession getPresentationSession()

Gets the presentation session object associated with this crypto object.

Returns
@Nullable PresentationSession

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

getSignature

Added in 1.0.0
public @Nullable Signature getSignature()

Gets the signature object associated with this crypto object.

Returns
@Nullable Signature

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