FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
mattchow_FTNT
Article Id 208839
Description This article describe another way to reset admin password if maintainer account also disabled.
Scope FortiGate.
Solution

The most important requirement to reset admin password is the user must have the latest backup configuration file of FortiGate, then open the configuration file using text editor or notepad, find the '# config system admin' section in the configuration file. The 'set password' field will be visible and follow with an encrypted algorithm as below.

 

config system admin

edit "admin"

set accprofile "super_admin"

set vdom "root"

set password ENC SH2zVB67Die9HGlNpeOYte0yo1r1Y46dHyL1TUD/RBU/WTMK9kQzqSw9vHcIdQ=

next

end

It is necessary to change the forgotten or lost password to replace the encrypted algorithm, for example, 'admin' is the password to change. Change it as shown below, and save the configuration file after the change.

 

config system admin

edit "admin"

set accprofile "super_admin"

set vdom "root"

set password admin

next

end

 

After, format and reload the image as shown in the guidance link below:

Technical Tip: Formatting and loading FortiGate firmware image using TFTP

 

The system will then boot up with no configuration file, and it will be necessary to restore the configuration file. It will be possible to access FortiGate after restoring the configuration.

 

Additional info:

The admin password could also be recovered if the FortiGate has a 'FortiGate Cloud paid Subscription' and is currently connected to/managed on FortiGate Cloud. See this article for more information.

 

Note:

If the FortiGate's latest Backup config file is not available and the FortiGate is not managed in the FortiGate Cloud, there is no way to recover the 'admin' account without keeping the latest setup of the FortiGate.
FortiGate will be Formatted.


80F, 81F, 70F, 71F, 60E/61E, 60F/61F, 40F, 80E, 60C, and other models intended for small businesses have an external RESET button to factory reset the FortiGate: Technical Tip: How To Reset To Factory Default Configuration using external button

Reload the image as shown in: Technical Tip: Formatting and loading FortiGate firmware image using TFTP.

 

FortiGate will be reconfigured from scratch. The Fortinet Team does not have any kind of 'back end access' to FortiGate to recover Administrator account details.

Related article:
Technical Tip: Resetting a lost admin password