| CLASS info |
| public class BioAuthnPrompt extends java.lang.Object |
| Represents a main entry point for the fingerprint authentication API of FIDO BioAuthn. |
| Type | Name | Desc |
| int | ERROR_HW_UNAVAILABLE | Hardware is unavailable. Try again later. |
| int | ERROR_UNABLE_TO_PROCESS | The sensor cannot process the current fingerprint image. |
| int | ERROR_TIMEOUT | The current request timed out. |
| int | ERROR_NO_SPACE | The storage space is insufficient for the operation. |
| int | ERROR_CANCELED | The operation is canceled because the fingerprint authentication sensor is unavailable. |
| int | ERROR_LOCKOUT | The operation is canceled because the API is locked when the number of attempts reaches the maximum. |
| int | ERROR_VENDOR | Vendor-defined errors. |
| int | ERROR_LOCKOUT_PERMANENT | The operation is canceled when the number of fingerprint authentication locking times reaches the maximum. |
| int | ERROR_USER_CANCELED | The user cancels the fingerprint authentication. |
| int | ERROR_NO_BIOMETRICS | The user has not registered any fingerprints. |
| int | ERROR_HW_NOT_PRESENT | The user device is not equipped with a fingerprint sensor. |
| int | ERROR_NEGATIVE_BUTTON | The user cancels the authentication. |
| int | ERROR_NO_DEVICE_CREDENTIAL | No PIN or password is set for the device. |
| int | ERROR_SYS_INTEGRITY_FAILED | The device failed the system integrity check. |
| int | ERROR_CRYPTO_VERIFY_FAILED | The fingerprint authentication result failed the key-based encryption certification. |
| int | ERROR_HMS_FRAMEWORK_ERROR | HMS Core Framework error. |
| int | ERROR_UNSUPPORTED_OS_VER | This version of operating system does not support fingerprint authentication. |
| Method name |
BioAuthnPrompt(androidx.fragment.app.FragmentActivity fragmentActivity, java.util.concurrent.Executor executor, BioAuthnCallback callback) Constructs a BioAuthnPrompt object for fingerprint authentication, which is used to call the fingerprint authentication API of FIDO BioAuthn. |
| BioAuthnPrompt(androidx.fragment.app.Fragment fragment, java.util.concurrent.Executor executor, BioAuthnCallback callback)Constructs a BioAuthnPrompt object for fingerprint authentication, which is used to call the fingerprint authentication API of FIDO BioAuthn. |
| Return type | Method name |
| void | auth(final BioAuthnPrompt.PromptInfo info, final CryptoObject crypto) Displays a fingerprint authentication pop-up for the user. Associates with a private key or a public-private key pair, which can be used only after the user passes the fingerprint authentication. |
| void | auth(final BioAuthnPrompt.PromptInfo info) Displays a fingerprint authentication pop-up for users. |
| void | Closes the fingerprint authentication pop-up. |
| Constant |
| public static final int ERROR_VENDOR |
Returned in the errorCode parameter sent by the onAuthError method of BioAuthnCallback when the auth method is called. Value: 8 Vendor-defined errors. |
| Method |
| public BioAuthnPrompt(androidx.fragment.app.FragmentActivity fragmentActivity, java.util.concurrent.Executor executor, BioAuthnCallback callback) |
Parameters
| Parameter name | Parameter desc |
| fragmentActivity | FragmentActivity of an Android app. |
| executor | Executor for processing the callback event. |
| callback | Callback object for processing the authentication event. |
| Method |
| public BioAuthnPrompt(androidx.fragment.app.Fragment fragment, java.util.concurrent.Executor executor, BioAuthnCallback callback) |
Parameters
| Parameter name | Parameter desc |
| fragment | Fragment of an Android app. |
| executor | Executor for processing the callback event. |
| callback | Callback object for processing the authentication event. |
Parameters
| Parameter name | Parameter desc |
| info | Information displayed in the fingerprint authentication pop-up, which is created using BioAuthnPrompt.PromptInfo.Builder. |
| crypto | Encryption object associated with fingerprint authentication. |
| Method |
| public void auth(final BioAuthnPrompt.PromptInfo info) |
| Displays a fingerprint authentication pop-up for users. |
Parameters
| Parameter name | Parameter desc |
| info | Information displayed in the fingerprint authentication pop-up, which is created using BioAuthnPrompt.PromptInfo.Builder. |
| Method |
| public void cancelAuth() |
| Closes the fingerprint authentication pop-up. |