passcode

How to use passcode lock scene in my app?

落爺英雄遲暮 提交于 2019-12-31 03:48:08
问题 Actually, I building an app which contains local authentication. My code so far: func authenticateUser() { let authenticationContext = LAContext() var error: NSError? let reasonString = "Touch the Touch ID sensor to unlock." // Check if the device can evaluate the policy. if authenticationContext.canEvaluatePolicy(LAPolicy.deviceOwnerAuthenticationWithBiometrics, error: &error) { authenticationContext.evaluatePolicy( .deviceOwnerAuthenticationWithBiometrics, localizedReason: reasonString,

How to programmatically check support of Touch ID, Face Id ,Password and pattern lock in React-Native

柔情痞子 提交于 2019-12-23 09:35:29
问题 I have implemented react-native-fingerprint-scanner in my application its working fine for Touch Id . Now I wanted to add authentication for Touch ID, Face Id, Pass code for both platform Is there any to check whether your device support or not respectively it will ask for lock pattern ? Also I have tried using react-native-touch-id but it is not working me for Face Id Is there any way to achieve this for both platform (iOS/android)? Reference:Link 回答1: react-native-touch-id should work for

How to use passcode lock scene in my app?

允我心安 提交于 2019-12-02 07:01:50
Actually, I building an app which contains local authentication. My code so far: func authenticateUser() { let authenticationContext = LAContext() var error: NSError? let reasonString = "Touch the Touch ID sensor to unlock." // Check if the device can evaluate the policy. if authenticationContext.canEvaluatePolicy(LAPolicy.deviceOwnerAuthenticationWithBiometrics, error: &error) { authenticationContext.evaluatePolicy( .deviceOwnerAuthenticationWithBiometrics, localizedReason: reasonString, reply: { (success, evalPolicyError) in if success { print("success") } else { if let evaluateError = error