Class GroovyMfaService
java.lang.Object
de.uplanet.lucy.server.mfa.scripting.groovy.GroovyMfaService
-
Method Summary
Modifier and TypeMethodDescriptionboolean
clearAuthenticationCode
(String p_strRefId) Remove an authentication code from the MFA authentication service.static GroovyMfaService
Create an instance of this API class.sendAuthenticationCodeSms
(Map<String, Object> p_params) Send an authentication code via SMS.sendAuthenticationCodeVoice
(Map<String, Object> p_params) Send an authentication code via voice call.boolean
verifyAuthenticationCode
(Map<String, Object> p_params) Verify an authentication code previously sent withsendAuthenticationCodeSms(Map)
orsendAuthenticationCodeVoice(Map)
.
-
Method Details
-
createInstance
Create an instance of this API class.- Returns:
- A new instance of this class.
-
sendAuthenticationCodeSms
Send an authentication code via SMS.The caller must store the returned reference ID for later
verification
of the authentication code received by the user.If a
secret
is provided then the same secret must be provided forverification
.Parameters:
to
(required): The recipients phone number.secret
(optional): A secret used to verify the authentication code, e.g. a user password. If none is supplied then a secret derived from the returned reference ID is used.lang
(optional): The language to be used. If none is supplied then the default language of the portal is used.
- Parameters:
p_params
- Named parameters (see above).- Returns:
- The reference ID that uniquely identifies the sent authentication code within the system.
-
sendAuthenticationCodeVoice
Send an authentication code via voice call.The caller must store the returned reference ID for later
verification
of the authentication code received by the user.If a
secret
is provided then the same secret must be provided forverification
.Parameters:
to
(required): The recipients phone number.secret
(optional): A secret used to verify the authentication code, e.g. a user password. If none is supplied then a secret derived from the returned reference ID is used.lang
(optional): The language to be used. If none is supplied then the default language of the portal is used.
- Parameters:
p_params
- Named parameters (see above).- Returns:
- The reference ID that uniquely identifies the sent authentication code within the system.
-
verifyAuthenticationCode
Verify an authentication code previously sent withsendAuthenticationCodeSms(Map)
orsendAuthenticationCodeVoice(Map)
.Parameters:
refId
(required): The unique reference ID returned bysendAuthenticationCodeSms(Map)
orsendAuthenticationCodeVoice(Map)
.code
(required): The authentication code received by the user.secret
(optional): The secret given when the authentication code was sent.
- Parameters:
p_params
- Named parameters (see above).
-
clearAuthenticationCode
Remove an authentication code from the MFA authentication service.- Parameters:
p_strRefId
- The unique reference ID used to identify the code.- Returns:
true
if the authentication code is valid, orfalse
if it is invalid or expired.
-