Package com.thalesgroup.gemalto.d1.authn
Interface D1Authn
-
public interface D1Authn
Entry point to access the Authn features.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
enrollAuthnCredentials(AuthnType preferredAuthnType, D1Task.Callback<Void> callback)
Enrols the end user's device for authentication.void
fetchAuthnRequest(D1Task.Callback<Void> callback)
Fetches a pending authentication request.AuthnType
getEnrolledAuthnType()
Get enrolled authn type.void
unenrollAuthnCredentials(D1Task.Callback<Void> callback)
Unenroll the user's device.
-
-
-
Method Detail
-
enrollAuthnCredentials
void enrollAuthnCredentials(@Nullable AuthnType preferredAuthnType, @NonNull D1Task.Callback<Void> callback)
Enrols the end user's device for authentication.- Parameters:
preferredAuthnType
- The preferred authn type. IfAuthnType.BIOMETRIC
is selected and BIOMETRICS are not setup on the device, enroll authentication credential will giveD1Exception.ErrorCode.ERROR_CANCELLED
IfAuthnType.PLATFORM
is selected and BIOMETRICS are not setup on the device, enroll authentication credential will fallback to device keyguard IfAuthnType.PLATFORM
is selected and BIOMETRICS and keyguard are not setup on the device, enroll authentication credential will giveD1Exception.ErrorCode.ERROR_CANCELLED
callback
- The callback is invoked when the enroll authentication credential process is completed. When it succeeds, the returned argument of theD1Task.Callback.onSuccess(Object)
is always null.
Possible errors:
D1Exception.ErrorCode.ERROR_AUTHN
D1Exception.ErrorCode.ERROR_AUTHN_NOT_ENROLLED
D1Exception.ErrorCode.ERROR_CANCELLED
D1Exception.ErrorCode.ERROR_DEVICE_ENVIRONMENT_UNSAFE
D1Exception.ErrorCode.ERROR_AUTHN_ACCESS_DENIED
D1Exception.ErrorCode.ERROR_AUTHN_USER_LOCKOUT
D1Exception.ErrorCode.ERROR_AUTHN_INVALID_ENROLLMENT_TOKEN
-
unenrollAuthnCredentials
void unenrollAuthnCredentials(@NonNull D1Task.Callback<Void> callback)
Unenroll the user's device.- Parameters:
callback
- The callback invoked when the unenrollment of authn credential process is completed. If device is not enrolled, success callback is invoked.
Possible errors:
- Since:
- 3.1.0
-
-
fetchAuthnRequest
void fetchAuthnRequest(@NonNull D1Task.Callback<Void> callback)
Fetches a pending authentication request.- Parameters:
callback
- The callback is invoked when the fetch authn request process is completed. When it succeeds, the returned argument of theD1Task.Callback.onSuccess(Object)
is always null.
Possible errors:
-