EMAuthService

Objective-C

@protocol EMAuthService <NSObject>

Swift

protocol EMAuthService : NSObjectProtocol

A protocol that represents authentication service.

Since

3.2
  • Get authentication mode reference corresponding to this service.

    Since

    3.2

    Declaration

    Objective-C

    - (id<EMAuthMode>)authMode;

    Swift

    func authMode() -> (any EMAuthMode)!

    Return Value

    current auth mode.

  • Indicates if the authentication mode is supported by the hardware.

    Since

    3.2

    Declaration

    Objective-C

    - (BOOL)isSupported:(NSError **)error;

    Parameters

    error

    If an error occurs, upon return contains an NSError object that describes the problem. If you are not interested in possible errors, you may pass in NULL.

    Return Value

    ‘YES’ if authentication is supported, ‘NO’ otherwise.

  • Indicates if the authentication mode is configured and ready for use. For example, a user may need to configure the OS to use a particular feature, such as TouchID, Face ID, before this authentication mode can be used.

    TouchID authentication mode is configured only if the following conditions met:

    1. At least one touch ID user is registered into the system
    2. Touch ID service is available. If the touch ID is temporarily locked out because there were too many failed Touch ID attempts, the function will return false and an error.

    Face ID authentication mode is configured only if the following conditions met:

    1. Face ID authentication service is initialized, and
    2. One user is enrolled.

    Since

    3.2

    Declaration

    Objective-C

    - (BOOL)isConfigured:(NSError **)error;

    Parameters

    error

    If an error occurs, upon return contains an NSError object that describes the problem. If you are not interested in possible errors, you may pass in NULL.

    Return Value

    ‘YES’ if the platform is correctly configured to support the authentication mode; ‘NO’ otherwise.

  • Indicates if the authentication mode is supported by the hardware.

    Note

    Use this API instead of isSupported: if you are using Swift in your code

    Since

    6.1.0

    Declaration

    Objective-C

    - (BOOL)isSupported;

    Swift

    func isSupported() -> Bool

    Return Value

    ‘YES’ if authentication is supported, ‘NO’ otherwise.

  • Indicates if the authentication mode is configured and ready for use. For example, a user may need to configure the OS to use a particular feature, such as TouchID, Face ID, before this authentication mode can be used.

    TouchID authentication mode is configured only if the following conditions met:

    1. At least one touch ID user is registered into the system
    2. Touch ID service is available. If the touch ID is temporarily locked out because there were too many failed Touch ID attempts, the function will return false and an error.

    Face ID authentication mode is configured only if the following conditions met:

    1. Face ID authentication service is initialized, and
    2. One user is enrolled.

    Note

    Use this API instead of isConfigured: if you are using Swift in your code

    Since

    6.1.0

    Declaration

    Objective-C

    - (BOOL)isConfigured;

    Swift

    func isConfigured() -> Bool

    Return Value

    ‘YES’ if the platform is correctly configured to support the authentication mode; ‘NO’ otherwise.