TouchIDChallenge

public final class TouchIDChallenge : ChallengeProtocol

The fingerprint challenge mechanism is an Apple Touch ID LocalAuthentication prompt for validation of an enrolled fingerprint.

  • Initializes a new TouchIDChallenge mechanism.

    Declaration

    Swift

    required public convenience init()
  • Initializes a new TouchIDChallenge mechanism.

    Declaration

    Swift

    required public init(messagePrompt: String)
  • The name of the mechanism.

    Declaration

    Swift

    public var name: String
  • The description of the mechanism.

    Declaration

    Swift

    public var description: String
  • The identifier of the mechanism.

    Remark

    The identifier value is: urn:ibm:security:authentication:asf:mechanism:mobile_user_approval:fingerprint.

    Declaration

    Swift

    public var identifier: String
  • The postback URI of the mechanism.

    Remark

    This value is set in the parse method.

    Declaration

    Swift

    public var postbackUri: String
  • The state represents the unique identifier of the machanism request.

    Remark

    This value is set in the parse method.

    Declaration

    Swift

    public var state: String
  • The message to display in the alert when prompted.

    Declaration

    Swift

    public fileprivate(set) var messagePrompt: String
  • An array of String representing names of key handles.

    Declaration

    Swift

    public fileprivate(set) var keyHandles: [String] = []
  • The text representing the server challenge which requires signing.

    Declaration

    Swift

    public fileprivate(set) var challengeText: String = ""
  • The type of the enrollment challenge.

    Declaration

    Swift

    public var type: String
  • The type’s identifier, used to access the private key in the keychain. Only one challenge of this type can be enrolled, so there’s no overlap.

    Declaration

    Swift

    public var keyName = ""
  • The dictionary represeting the data that will be returned in the TouchIDChallenge.launchUI function.

    Remark

    The default is to return the challenge unsigned.

    Declaration

    Swift

    public var challengeData: [String: Any] = ["signedChallenge": ""]
  • Initializes a new challenge mechanism.

    Throws

    IBMMobileKitError.invalidDataFromServer

    Declaration

    Swift

    public func parse(_ data: [String:Any]) throws -> TouchIDChallenge
  • This method launches the Apple Touch ID dialog for LocalAuthentication.

    Declaration

    Swift

    public func launchUI(_ viewController: UIViewController, completion: @escaping (_ data: [String: Any], _ error: Error?) -> Void)
  • This method launches the Apple Touch ID dialog for LocalAuthentication.

    Declaration

    Swift

    public func launchUI(_ completion: @escaping (_ data: [String:Any], _ error: Error?) -> Void)