| CLASS info |
| public class FingerprintManager extends java.lang.Object |
| Represents an entry point for the API for checking whether fingerprint authentication of FIDO BioAuthn is available. |
| Type | Name | Desc |
| int | FINGERPRINT_ACQUIRED_GOOD | The obtained fingerprint image is good. |
| int | FINGERPRINT_ACQUIRED_PARTIAL | The detected fingerprint image is incomplete. |
| int | FINGERPRINT_ACQUIRED_INSUFFICIENT | The fingerprint image is too noisy due to a detected condition (that is, dry skin) or a possible dirty sensor. |
| int | FINGERPRINT_ACQUIRED_IMAGER_DIRTY | The fingerprint image is too noisy due to suspected or detected dirt on the sensor. |
| int | FINGERPRINT_ACQUIRED_TOO_SLOW | The fingerprint image cannot be read due to lack of motion. |
| int | FINGERPRINT_ACQUIRED_TOO_FAST | The fingerprint image is incomplete due to quick motion. |
| int | FINGERPRINT_ACQUIRED_VENDOR: 1038 | A fingerprint is detected. |
| int | FINGERPRINT_ACQUIRED_VENDOR: 1012 | The fingerprint does not match. |
| int | FINGERPRINT_SUCCESS | No error is detected. |
| int | FINGERPRINT_ERROR_HW_UNAVAILABLE | Hardware is unavailable. |
| int | FINGERPRINT_ERROR_UNABLE_TO_PROCESS | The sensor cannot process the current fingerprint image. |
| int | FINGERPRINT_ERROR_TIMEOUT | The current request timed out. |
| int | FINGERPRINT_ERROR_NO_SPACE | The storage space is insufficient for the operation. |
| int | FINGERPRINT_ERROR_CANCELED | The operation is canceled because the fingerprint authentication sensor is unavailable. |
| int | FINGERPRINT_ERROR_LOCKOUT | The operation is canceled because the API is locked when the number of attempts reaches the maximum. |
| int | FINGERPRINT_ERROR_VENDOR | A vendor-defined error occurred. |
| int | FINGERPRINT_ERROR_LOCKOUT_PERMANENT | The operation is canceled when the number of fingerprint authentication locking times reaches the maximum. |
| int | FINGERPRINT_ERROR_USER_CANCELED | The user cancels the fingerprint authentication. |
| int | FINGERPRINT_ERROR_NO_FINGERPRINTS | The user has not registered any fingerprints. |
| int | FINGERPRINT_ERROR_HW_NOT_PRESENT | No fingerprint authentication hardware is provided. |
| int | FINGERPRINT_ERROR_SYS_INTEGRITY_FAILED | The device failed the system integrity check. |
| int | FINGERPRINT_ERROR_CRYPTO_VERIFY_FAILED | The fingerprint authentication result failed the key-based encryption verification. |
| int | FINGERPRINT_ERROR_HMS_FRAMEWORK_ERROR | An HMS Core framework error occurred. |
| int | FINGERPRINT_ERROR_UNSUPPORTED_OS_VER | This version of operating system does not support fingerprint authentication. |
| Method name |
FingerprintManager(android.app.Activity activity, java.util.concurrent.Executor executor, BioAuthnCallback callback) Constructs a FingerprintManager object for fingerprint authentication. The object is used to call the BioAuthn fingerprint authentication API of HUAWEI FIDO. |
FingerprintManager(android.app.Fragment fragment, java.util.concurrent.Executor executor, BioAuthnCallback callback) Constructs a FingerprintManager object for fingerprint authentication. The object is used to call the BioAuthn fingerprint authentication API of HUAWEI FIDO. |
| Return type | Method name |
| int | canAuth() Checks whether fingerprint authentication is available. |
| void | auth(final CryptoObject crypto) Performs fingerprint authentication. This method is associated with a private key or public-private key pair, which can be used only after the user passes the fingerprint authentication. |
| void | auth() Performs fingerprint authentication. |
| void | Cancels fingerprint authentication. |
| Constant |
| public static final int FINGERPRINT_ACQUIRED_GOOD |
Value: 0 The obtained fingerprint image is good. |
public static final int FACE_ACQUIRED_VENDOR:1038
Value: 1038
Returned using the helpCode parameter in the onAuthHelp method of BioAuthnCallback when the auth method is called.A fingerprint is detected.
| Constant |
| public static final int FINGERPRINT_SUCCESS |
Value: 0 Fingerprint authentication is available (with registered fingerprints and available authentication hardware). |
| Constant |
| public static final int FINGERPRINT_ERROR_HW_UNAVAILABLE |
Value: 1 Hardware is unavailable. |
| Constant |
| public static final int FINGERPRINT_ERROR_NO_FINGERPRINTS |
| Value: 11The user has not registered any fingerprints. |
| Constant |
| public static final int FINGERPRINT_ERROR_NO_FINGERPRINTS |
| Returned by the canAuth method.Value: 12No fingerprint authentication hardware is provided. |
| Method |
| public FingerprintManager(android.app.FragmentActivity activity, java.util.concurrent.Executor executor, BioAuthnCallback callback) |
Parameters
| Parameter name | Parameter desc |
| activity | Activity of an Android app, which references the activity of the client. |
| executor | Executor for processing the callback event. |
| callback | Callback object for processing the authentication event. |
| Method |
| public FingerprintManager(android.app.Fragment fragment, java.util.concurrent.Executor executor, BioAuthnCallback callback) |
Parameters
| Parameter name | Parameter desc |
| fragment | Fragment of an Android app, which references the fragment of the client. |
| executor | Executor for processing the callback event. |
| callback | Callback object for processing the authentication event. |
| Method |
| public int canAuth() |
| Checks whether fingerprint authentication is available. |
Return
| type | desc |
| int | FINGERPRINT_SUCCESS: Fingerprint authentication is available (with registered fingerprints and available authentication hardware). FINGERPRINT_ERROR_HW_UNAVAILABLE: Hardware is unavailable. FINGERPRINT_ERROR_NO_FINGERPRINTS: The user has not registered any fingerprints. FINGERPRINT_ERROR_NO_HARDWARE: No fingerprint authentication hardware is provided. FINGERPRINT_ERROR_UNSUPPORTED_OS_VER: This version of operating system does not support fingerprint authentication. |
Parameters
| Parameter name | Parameter desc |
| crypto | Encryption object associated with fingerprint authentication. |
| Method |
| public void auth() |
| Performs fingerprint authentication. |
| Method |
| public void cancelAuth() |
| Closes the fingerprint authentication pop-up. |