MfaRegistrationContext
public final class MfaRegistrationContext : RegistrationProtocol
The MfaRegistrationContext
enables mobile applications to register a users device to IBM Security Access Manager. The registration process requires the mobile application to support QR code scanning.
-
The unique token to identify the device for push notifcations.
Remark
This property should be assigned in the String.Declaration
Swift
public var deviceToken: String?
-
Returns the shared defaults object.
Declaration
Swift
public static let shared: MfaRegistrationContext
-
Get or set the session delegate that handles authentication requests. Refer to URLSessionDelegate. Default is
nil
.Declaration
Swift
public var serverTrustDelegate: URLSessionDelegate?
-
The timeout interval for the request, in seconds. The default is 30 seconds.
Declaration
Swift
public var timeoutInterval: TimeInterval
-
Acquires additional information to complete a registration.
Declaration
Swift
public func discover(_ endpointUrl: String, completion: @escaping (MfaRegistrationResult) -> Void)
Parameters
endpointUrl
The endpoint that gets the additional information for completing registration.
completion
The function delegate that is invoked with a
MfaRegistrationResult
. -
Unregister the device.
Declaration
Swift
public func unregisterDevice(_ endpointUrl: String, token: OAuthToken, completion: @escaping (MfaUnregisterDeviceResult) -> Void)
Parameters
endpointUrl
The endpoint to unregister the device.
token
The
OAuthToken
to consume with the request.completion
The function delegate that is invoked with a
MfaUnregistraterDeviceResult
.