Fortigate Firewall Local User MFA by E-mail

To activate MFA via e-mail for Fortigate local users, we need to write a command via CLI.

config user local
edit "mustafa.turkoglu"
set type password
set two-factor email
set email-to "info@mustafaturkoglu.net"
set passwd-time 2024-06-10 12:21:56
set passwd ENC 20M4tyeMqoZ7cQvWNgEw7g29Kmab63WFwkDnO/FHW8fk2+LCkzxwai7VLad5BjbicpmasdasdjadlRX8tXl2p/736OZGZ+8cANc/0FhRQ/b4GZzS0GzizFZNpFyIHNDdi7ySVWxBhJuT0sUimmSFaq+wmM1ZKTHqtMhgOKBg9VR9Og==
next
end

Before setting up mail, the following SMTP server must be set.