Open lsanil opened 5 years ago
How does your config look? Can you share some code?
sure, thank you for your reply. I downloaded the sample and tried on iOS simulator. Here is the config
struct Shared {
static let keypair: EllipticCurveKeyPair.Manager = {
EllipticCurveKeyPair.logger = { print($0) }
let publicAccessControl = EllipticCurveKeyPair.AccessControl(protection: kSecAttrAccessibleAlwaysThisDeviceOnly, flags: [])
let privateAccessControl = EllipticCurveKeyPair.AccessControl(protection: kSecAttrAccessibleAfterFirstUnlockThisDeviceOnly, flags: {
return EllipticCurveKeyPair.Device.hasSecureEnclave ? [.userPresence, .privateKeyUsage] : [.userPresence]
}())
let config = EllipticCurveKeyPair.Config(
publicLabel: "no.agens.sign.public",
privateLabel: "no.agens.sign.private",
operationPrompt: "Sign transaction",
publicKeyAccessControl: publicAccessControl,
privateKeyAccessControl: privateAccessControl,
token: .secureEnclaveIfAvailable)
return EllipticCurveKeyPair.Manager(config: config)
}()
}
it looks it is issue only on simulator, on real iOS device, see this working properly.
I don't remember if this is expected behavior. I think it is, but I am not entirely sure. What happens if you trigger LAContext methods on simulator? Does it show any UI?
What happens if you trigger LAContext methods on simulator? Does it show any UI?
yes it also appear on simulator.
Thank you for great library. Learned a lot.
I am trying the sample on iOS simulator via XCode Version 10.1 (10B61). I configured Face ID in simulator. But I can't get Face ID prompt working for both sign or decrypt operations. Has anything changed recently in simulator behavior?
iOS device I selected in simulator: iPhoneXS Max Xcode version: 10.1 (10B61) Mac OSX version: macOS High Siera Version 10.13.6