Determine if biometric hardware is present and the user has enrolled biometrics on Android P

Google finally solved this problem with Android Q The android.hardware.biometrics.BiometricManager#canAuthenticate() method can be used to determine if biometrics can be used. The method can be used to determine if biometric hardware is present and if the user is enrolled or not. Returns BIOMETRIC_ERROR_NONE_ENROLLED if the user does not have any enrolled, or BIOMETRIC_ERROR_HW_UNAVAILABLE if none … Read more

Can we test Face ID in simulator?

Simulator does not recognise a face but allows you to simulate a matching and non-matching faces, if you’ve enabled Enrolled option from Face ID. Add following code to your view controller and try with Face-ID import LocalAuthentication class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() localAuthentication() } func localAuthentication() -> Void { let laContext … Read more