Class DeviceBindingCallback
-
- All Implemented Interfaces:
-
java.io.Serializable,org.forgerock.android.auth.callback.Binding,org.forgerock.android.auth.callback.Callback
public class DeviceBindingCallback extends AbstractCallback implements Binding
Callback to collect the device binding information
-
-
Field Summary
Fields Modifier and Type Field Description private final StringuserIdprivate final StringuserNameprivate final Stringchallengeprivate final DeviceBindingAuthenticationTypedeviceBindingAuthenticationTypeprivate final Stringtitleprivate final Stringsubtitleprivate final Stringdescriptionprivate final Integertimeoutprivate final Attestationattestationprivate final Function1<DeviceBindingAuthenticationType, DeviceAuthenticator>deviceAuthenticatorIdentifier
-
Constructor Summary
Constructors Constructor Description DeviceBindingCallback(JSONObject jsonObject, Integer index)DeviceBindingCallback()
-
Method Summary
Modifier and Type Method Description final StringgetUserId()The userId received from server final StringgetUserName()The userName received from server final StringgetChallenge()The challenge received from server final DeviceBindingAuthenticationTypegetDeviceBindingAuthenticationType()The authentication type of the journey final StringgetTitle()The title to be displayed in biometric prompt final StringgetSubtitle()The subtitle to be displayed in biometric prompt final StringgetDescription()The description to be displayed in biometric prompt final IntegergetTimeout()The timeout to be to expire the biometric authentication final AttestationgetAttestation()Enable Attestation StringgetType()Return the type of the Callback, the type name should align with the Callback type returned from AM final UnitsetJws(String value)Input the JWS key to the server final UnitsetDeviceName(String value)Input the Device Name to the server final UnitsetDeviceId(String value)Input the Device Id to the server UnitsetClientError(String value)Input the Client Error to the server Unitbind(Context context, Function1<DeviceBindingAuthenticationType, DeviceAuthenticator> deviceAuthenticator, FRListener<Void> listener)Bind the device. Unitbind(Context context, FRListener<Void> listener)Bind the device. Unitbind(Context context, Function1<DeviceBindingAuthenticationType, DeviceAuthenticator> deviceAuthenticator)Bind the device. CryptoKeygetCryptoKey()-
Methods inherited from class org.forgerock.android.auth.callback.Binding
getDeviceAuthenticator, getDeviceAuthenticatorIdentifier, getDuration, getExpiration, handleException -
Methods inherited from class org.forgerock.android.auth.callback.AbstractCallback
getContent, getInputValue, getInputValue, get_id -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
DeviceBindingCallback
DeviceBindingCallback(JSONObject jsonObject, Integer index)
-
DeviceBindingCallback
DeviceBindingCallback()
-
-
Method Detail
-
getUserName
final String getUserName()
The userName received from server
-
getChallenge
final String getChallenge()
The challenge received from server
-
getDeviceBindingAuthenticationType
final DeviceBindingAuthenticationType getDeviceBindingAuthenticationType()
The authentication type of the journey
-
getSubtitle
final String getSubtitle()
The subtitle to be displayed in biometric prompt
-
getDescription
final String getDescription()
The description to be displayed in biometric prompt
-
getTimeout
final Integer getTimeout()
The timeout to be to expire the biometric authentication
-
getAttestation
final Attestation getAttestation()
Enable Attestation
-
getType
String getType()
Return the type of the Callback, the type name should align with the Callback type returned from AM
-
setJws
final Unit setJws(String value)
Input the JWS key to the server
- Parameters:
value- The JWS value.
-
setDeviceName
final Unit setDeviceName(String value)
Input the Device Name to the server
- Parameters:
value- The device name value.
-
setDeviceId
final Unit setDeviceId(String value)
Input the Device Id to the server
- Parameters:
value- The device Id.
-
setClientError
Unit setClientError(String value)
Input the Client Error to the server
- Parameters:
value- DeviceBind ErrorType .
-
bind
@JvmOverloads() Unit bind(Context context, Function1<DeviceBindingAuthenticationType, DeviceAuthenticator> deviceAuthenticator, FRListener<Void> listener)
Bind the device. Calling the bind function, the existing bounded keys will be removed. If don't want to replace or remove existing keys, please use FRUserKeys to check existing keys before calling this method
- Parameters:
context- The Application ContextdeviceAuthenticator- A function to return a DeviceAuthenticator, deviceAuthenticatorIdentifier will be used if not providedlistener- The Listener to listen for the result
-
bind
@JvmOverloads() Unit bind(Context context, FRListener<Void> listener)
Bind the device. Calling the bind function, the existing bounded keys will be removed. If don't want to replace or remove existing keys, please use FRUserKeys to check existing keys before calling this method
- Parameters:
context- The Application Contextlistener- The Listener to listen for the result
-
bind
Unit bind(Context context, Function1<DeviceBindingAuthenticationType, DeviceAuthenticator> deviceAuthenticator)
Bind the device. Calling the bind function, the existing bounded keys will be removed. If don't want to replace or remove existing keys, please use FRUserKeys to check existing keys before calling this method
- Parameters:
context- The Application ContextdeviceAuthenticator- A function to return a DeviceAuthenticator, deviceAuthenticatorIdentifier will be used if not provided
-
getCryptoKey
CryptoKey getCryptoKey()
-
-
-
-