How to enable GUI Access on Fortigate / VM Firewall Through CLI console

When installing Fortigate-VM you will need to start the settings from CLI in order to get GUI access, you will need to setup interface for admin access. here is the steps :

  • Fortinet_Lab # config system interface
  • Fortinet_Lab (interface) # edit port1
  • Fortinet_Lab (port1) # set ip
  • Fortinet_Lab (port1) # set allowaccess ping http https fgfm
    • ssh SSH access.
    • snmp SNMP access.
    • telnet TELNET access.
    • radius-acct RADIUS accounting access.
    • probe-response Probe access.
    • capwap CAPWAP access.
    • ftm FTM access.
  • Fortinet_Lab (port1) # set allowaccess ping http https fgfm ftm ssh >> Remember to allow the https and http connection to firewall on this port. You can also allow other options to connect to firewall but those will need to be specifically allowed under each port where you want to connect from your network. For example we have allowed ping, ssh etc on firewall to this port (port1).
  • Fortinet_Lab (port1) # end

To Verify setting got configure :

Fortinet_Lab # show system interface port1


config system interface

    edit “port1”

set vdom “root”

        set ip

        set allowaccess ping https ssh http fgfm ftm

  set mode static

set type physical

set snmp-index 1



Now configure the static route :

Fortinet_Lab # config router static

Fortinet_Lab (static) # edit 1

new entry ‘1’ added

Fortinet_Lab (1) # set gateway

Fortinet_Lab (1) # set dst

Fortinet_Lab (1) # set device port1

Fortinet_Lab (1) # end

Verify the route:

Fortinet_Lab # show router static

config router static

edit 1

set gateway

set device “port1”



Fortinet_Lab #

Now check ping out :

Fortinet_Lab #execute ping

Now you will be able to access the firewall on port 80 only since there is no certificate create yet, so start access it from port 80

Good Luck

Leave a Reply

Your email address will not be published. Required fields are marked *