You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I try to enable the keychain synchronization together with a Touch ID enabled login.
Unfortunately I receive the following error whenever I set .synchronizable(true):
OSStatus error:[-50] One or more parameters passed to a function were not valid.
error: Optional(Error Domain=com.kishikawakatsumi.KeychainAccess.error Code=-50 "One or more parameters passed to a function were not valid." UserInfo=0x7fb271d3e6b0 {NSLocalizedDescription=One or more parameters passed to a function were not valid.})
And thats the example code:
let keychain = Keychain(service: "my.service").synchronizable(true)
keychain.remove("default.tenantid")
dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0)) {
let failable = keychain
.authenticationPrompt("Please auth!")
.getStringOrError("default.tenantid")
if failable.succeeded {
var tenantId: String? = failable.value
if tenantId == nil{
tenantId = NSUUID().UUIDString
let error = keychain
.accessibility(.WhenPasscodeSetThisDeviceOnly, authenticationPolicy: .UserPresence)
.set(tenantId!, key: "default.tenantid")
if error != nil {
println("error: \(error)")
// Error handling if needed...
}
}
//logged in
println(tenantId)
} else {
println("error: \(failable.error?.localizedDescription)")
// Error handling if needed...
}
}
What's wrong?
The text was updated successfully, but these errors were encountered:
I try to enable the keychain synchronization together with a Touch ID enabled login.
Unfortunately I receive the following error whenever I set .synchronizable(true):
error: Optional(Error Domain=com.kishikawakatsumi.KeychainAccess.error Code=-50 "One or more parameters passed to a function were not valid." UserInfo=0x7fb271d3e6b0 {NSLocalizedDescription=One or more parameters passed to a function were not valid.})
And thats the example code:
What's wrong?
The text was updated successfully, but these errors were encountered: