Configuring MFA by email

To add a new profile for multifactor authentication via email, use the following command:

Admin@nodename# create users mfa-profiles smtp <parameter>

Provide the following parameters:

Parameter

Description

name

The name of the MFA profile.

description

A description of the MFA profile.

notification-profile

Select the notification profile to use.

notification-sender

Email of the notification sender.

notification-subject

Notification subject.

notification-body

Body of the email. In the message body, you can use a special variable named {2fa_auth_code} that will be replaced by the one-time password. The notification text is separated by quotation marks ("").

code-lifetime

One-time password validity period (in seconds).

To edit a profile for multifactor authentication via email, use the following command:

Admin@nodename# set users mfa-profiles smtp <mfa-email-profile> <parameter>

The parameters available to update are identical to those used to create a profile.

Example of creating and editing a profile for multifactor authentication via email:

Admin@nodename# create users mfa-profiles smtp name "Test SMTP MFA profile" notification-profile "Example SMTP profile" notification-sender sender@example.org notification-subject "Test notification subj" notification-body "Test notification text" Admin@nodename# show users mfa-profiles smtp "Test SMTP MFA profile" name : Test SMTP MFA profile notification-profile : Example SMTP profile notification-sender : sender@example.org notification-subject : Test notification subj notification-body : Test notification text code-lifetime : 60 Admin@nodename# set users mfa-profiles smtp "Test SMTP MFA profile" code-lifetime 70 Admin@nodename# show users mfa-profiles smtp "Test SMTP MFA profile" name : Test SMTP MFA profile notification-profile : Example SMTP profile notification-sender : sender@example.org notification-subject : Test notification subj notification-body : Test notification text code-lifetime : 70