Im using Touch id to identify iPhone users in my app, when is use canEvaluatePolicy: LAPolicyDeviceOwnerAuthenticationWithBiometrics
to evaluate if the user is eligible for using Touch id, but after many failed tries even if the user is eligible for using touch id, it returns FALSE
.
And that will lead the app to skip this step and thinks that the touch id is not supported in this device.
Here is the error i get:
Error Domain=com.apple.LocalAuthentication Code=-8 "Biometry is locked out." UserInfo={NSLocalizedDescription=Biometry is locked out.}
Go to settings—— Touch Id & Passcode ——Enter your passcode—- then disable the touch id for Itunes & App store.
It is a unique fingerprint sensor that allows you to connect to, or unlock, your device. In other words, Touch ID is a fingerprint identity sensor that allows you to not only have access to, but protect your device from intruders. 1 Touch ID. 1.1 How to Set Up Touch ID on iPhone and iPad.
Ok, I think that I found the answer. Hopefully it will help you. When you get
Error Domain=com.apple.LocalAuthentication Code=-8 "Biometry is locked out." UserInfo={NSLocalizedDescription=Biometry is locked out.}
iOS 10 blocks access to TouchID, it can be either unlocked by providing passcode on iOS unlock screen, accessing TouchID iOS settings and providing the passcode there or manually triggering the passcode screen from within the app. You can open the passcode screen using, following snippet.
let context = LAContext()
context.evaluatePolicy(LAPolicy.DeviceOwnerAuthentication,
localizedReason: reason,
reply: { (success, error) in
})
Of course you can first check if this policy can be evaluated.
So in the end, when the user successfully enters passcode, the biometry will be unlocked. Before iOS 10, this was done automatically by the operating system.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With