I am trying to get password entered by user from TKTokenPasswordAuthOperation. When system call beginAuthFor i am returning TKTokenPasswordAuthOperation. now i need password that user has entered. when i try to access password property in TKTokenPasswordAuthOperation class it is nil. How i can get that password.
TKTokenPasswordAuthOperation get password
I’ve sent mjza this answer via another channel but I thought I’d post a summary here for the benefit of all…
When implementing a persistent token (a direct subclass of TKTokenDriver
rather than a subclass of TKSmartCardToken
), request a password as follows:
-
Implement a subclass of the
TKTokenPasswordAuthOperation
class. -
Override its
finish()
method. -
In that override, look at the
password
property. -
Instantiate that class and return it from your
tokenSession(_:beginAuthFor:constraint:)
method,
I’ve filed a bug requesting that we add this info to the official docs (r. 90836142).
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"