MMFA mapping rule methods

Customize the OAuth PreTokenGeneration and PostTokenGeneration mapping rules by using these methods.

Sample mapping rules are available from System > Secure Settings > File Downloads under the access_control > examples > mapping rules directory.

The following limitations affect the attribute keys and values that are associated with the state_id by using the MMFAMappingExtUtils class:

  • Keys cannot be null or empty.
  • Values can only be null or empty when specified.
  • Associated key-value pairs are read-only and not case sensitive.
  • The push token is read-only and case sensitive.
registerAuthenticator

public static String registerAuthenticator(
      String stateId
      )

This method performs the final steps of registering an authenticator. Use the following parameters:

stateId

The state ID of the authorization grant. This parameter cannot be null or empty.

These responses come from the runtime after registration.

  • The new authenticator's ID if successful.
  • Null if not successful.
savePushToken

public static boolean savePushToken(
      String stateId,
      String pushToken,
      String applicationID
      )

This method saves the push token and application ID with the authorization grant state ID. Use the following parameters:

stateId

The state ID of the authorization grant. This parameter cannot be null or empty.

pushToken

The push token the authenticator application has received from its push notification service provider. This parameter cannot be null or empty.

applicationID

The application ID of the authenticator application. This parameter can be null or empty.

These responses come from the runtime.

  • True if successful.
  • False if not successful.
savePushToken

public static boolean savePushToken(
      String stateId,
      String pushToken
      )

This method saves the push token and application ID with the authorization grant state ID. Use the following parameters:

stateId

The state ID of the authorization grant. This parameter cannot be null or empty.

pushToken

The push token the authenticator application has received from its push notification service provider. This parameter cannot be null or empty.

These responses come from the runtime.

  • True if successful.
  • False if not successful.
saveDeviceAttributes

public static boolean saveDeviceAttributes(
      String stateId,
      String deviceName,
      String deviceType,
      String osVersion,
      String fingerprintSupport,
      String frontCameraSupport,
      String tenantId
      )

This method saves various device attributes with the authorization grant state ID. Use the following parameters:

stateId

The state ID of the authorization grant. This parameter cannot be null or empty.

deviceName

The name of the device the authenticator is installed on. This parameter can be null or empty. If empty, the value is cleared.

deviceType

The type of the device the authenticator is installed on. This parameter can be null or empty. If empty, the value is cleared.

osVersion

The OS version of the device the authenticator is installed on. This parameter can be null or empty. If empty, the value is cleared.

fingerprintSupport

The type of fingerprint sensor that is supported by the device. This parameter can be null or empty. If empty, the value is cleared.

frontCameraSupport

flag that indicates if the device has a front facing camera. This parameter can be null or empty. If empty, the value is cleared.

tenantId

The tenant ID for this registration, if the authenticator application is multi-tenant. This parameter can be null or empty. If empty, the value is cleared.

These responses come from the runtime.

  • True if successful.
  • False if not successful.