Challenge Message


#1

I’d like to customize the message during a challenge response, is there a way to do this?

For example, I have a policy with ‘challenge_response’ set to ‘totp’ and ‘otppin’ set to ‘userstore’. The user is prompted for their UserID and their password (ldap). They are then prompted for their otp, with the following message, ‘please enter otp’. I’d like to modify this message. I’ve located where this is set in tokenclass.py but am fully aware that modifying this now will just be overwritten on upgrade. Is there someway to modify this currently with a policy? If not can I request this as a feature?

Many thanks!


#2

Every tokenclass can overwrite the method create_challenge and probably will.
So your question depends on the token type! E.g. look at the SMS token (https://github.com/privacyidea/privacyidea/blob/master/privacyidea/lib/tokens/smstoken.py#L274) or the Email token (https://github.com/privacyidea/privacyidea/blob/master/privacyidea/lib/tokens/emailtoken.py#L242)

No, this currently can not be configured.