FortiOS 7.0.0 Best Practices Guide
FortiOS 7.0.0 Best Practices Guide
FortiOS 7.0.0
FORTINET DOCUMENT LIBRARY
[Link]
FORTINET BLOG
[Link]
FORTIGUARD LABS
[Link]
FEEDBACK
Email: techdoc@[Link]
2023-06-13 Updated Identity and access management on page 15, Certificate usage on page 17, and
Encrypted protocols on page 36.
2024-04-08 Added Migrating a FortiGate configuration manually using configuration files on page 24.
Registration
The FortiGate, and then its service contract, must be registered to have full access to Fortinet Customer Service and
Support, and FortiGuard services. The FortiGate can be registered in either the FortiGate GUI or the FortiCloud support
portal. The service contract can be registered from the FortiCloud support portal.
To verify the license status on the FortiGate, go to System > FortiGuard and check the License Information table. There
can be a delay of a few hours between when you register your device and when the license information on the FortiGate
is updated.
The License Information table can be used to confirm that the FortiGate is receiving the latest updates. Expand a service
in the table and hover over a version to see the day it was last updated. Some services have daily updates, but others will
remain unchanged for a longer period of time. For example, the AV engine can stay unchanged for months, while the AV
signature database can receive multiple updates a day.
If you are not receiving updates, ensure that the FortiGate's communication with FortiGuard is uninterrupted (see the
FortiOS Ports guide), and check the FortiGuard troubleshooting section in the FortiOS Administration Guide.
Basic configuration
As the first step on a new deployment, review default settings such as administrator passwords, certificates for GUI and
SSL VPN access, SSH keys, open administrative ports on interfaces, and default firewall policies.
As soon as the FortiGate is connected to the internet it is exposed to external risks, such as unauthorized access, man-
in-the-middle attacks, spoofing, DoS attacks, and other malicious activities from malicious actors. Either use the start up
wizard or manually reconfigure the default settings to tighten your security from the beginning.
For instructions on connecting to your devices GUI and CLI, see the FortiOS Administration Guide and the FortiGate
QuickStart Guides.
l Operating mode:
NAT mode is preferred for security purposes. NAT mode policies translate addresses in a more secure zone from
users that are in a less secure zone using a NATed IP address or IP address pool. This layer of obfuscation
prevents malicious actors on the internet from knowing the IP addresses of the resources in your LAN and DMZ.
Use transparent mode when a network is complex and does not allow for changes in the IP addressing scheme.
l Firmware:
If the shipped firmware is not the firmware that you will be running, either load the required firmware before doing
any configuration, or establish remote access for the additional firmware upload options (SFTP, FTP, SCP, HTTPS)
and then load the required firmware.
l Hostname:
Use a meaningful hostname. It is used in the CLI prompt, as the SNMP system name, as the FortiGate Cloud device
name, and as the device name in an HA configuration.
l System time:
Several FortiGate features rely on an accurate system time, such as logging and certificate related functions. It is
recommended that you use a Network Time Protocol (NTP) or Precision Time Protocol (PTP) server to set the
system time. If necessary, the system time can be set manually.
l Administrator password:
The admin administrator password must be set when you first log in to the FortiGate. Ensure that the password is
unique and has adequate complexity.
l Management interface:
Configure the IP address, subnet mask, and only the required administrative access services (such as HTTPS and
SSH) on the management interface.
Resources
Fortinet provides many resources to help you configure and use Fortinet devices, software, and services:
Customer Service & Support (FortiCloud) Start a chat, open a ticket, or call in for immediate
[Link] service. Be aware of your support SLA with regards
to receiving assistance based on the issue severity
and Return Merchandise Authorization (RMA)
replacement times.
Fortinet Training Institute Sign up for computer based or instructor led training
[Link] and hands on labs.
Management network
There are many benefits to using a management network for administrative access to your network devices:
l Reliability:
When management traffic is independent from production or business traffic, it does not have to compete for
resources and management access can be maintained when reconfiguring the production network.
l Simpler policies:
Using a management interface allows for policy separation of the management and production traffic. Policies with
specific purposes are easier to understand and troubleshoot.
l Security:
It is more difficult to access network devices on the production network when their management access is on a
separate network.
A single interface or VLAN interface in the management network should be dedicated for all administrative access.
Administrative access should be disabled on all other interfaces.
Avoid using the WAN interface, or a publicly exposed interface, for management, as it will be
subject to constant attacks.
Administrative settings
The following general administrative settings are recommended:
l Set the idle timeout time for administrators to a low value, preferably less that ten minutes.
l Use non-standard HTTPS and SSH ports for administrative access.
l Disable weak encryption protocols.
l Disable the maintainer account if the FortiGate device's physical security cannot be guaranteed.
The built-in maintainer account is used to log in to the FortiGate if you have lost all administrator credentials.
Physical access to the FortiGate device is required. If maintainer account is disabled and you lose all of your
administrator credentials, then you will no longer be able to access to access the FortiGate and it will need to be
reset to factory default settings.
l Replace the certificate that is offered for HTTPS access with a trusted certificate that has the FQDN or IP address of
the FortiGate.
l Configure the Fortinet Security Fabric when multiple FortiGates and fabric devices are used. It provides a single-
pane-of-glass administration, allowing administrators access to each device in the fabric using SSO.
A Fortinet Security Fabric includes a root FortiGate, downstream FortiGates, and other Fortinet fabric devices. A
maximum of 35 downstream FortiGates is recommended.
Configuration changes
Configuration changes on the FortiGate after its initial setup should follow a change procedure as part of your change
management plan.
For example, the following is a possible change procedure for changes to the FortiGate configuration:
l Make sure that all of the affected parties are aware of the upcoming change and have a platform to provide input.
l Define the required changes and the objective, to keep the task focused.
l If creating or changing policies, note the following:
l The purpose of the policy,
l The affected services, applications, users, and devices,
l The date that the policy is added and, if applicable, the date that it expires,
l The name of the person who added or edited the policy.
l Define the possible risks, and plans to mitigate them.
l Define a contingency, or back-out, plan.
l Create a backup of the working configuration before making any changes.
l Prepare a well defined workflow. This can be particularly important if multiple teams are involved.
l Schedule a maintenance window.
l Test the changes, and have them validated by any affected parties.
l Audit and document the completed work.
l Create a backup of the new configuration.
Always maintain a backup of the FortiGate's working configuration. Keeping multiple past
configurations is recommended. Backups can be created in the GUI, CLI, and API, and on
FortiManager and FortiCloud.
check-all the default option. The CPU flags current sessions that are affected by a firewall policy change or routing
change, as dirty. These sessions are revalidated to check whether they conform with the firewall policy and routing
configuration. If a sessions does not conform, it is flagged as blocked and removed from the session table and traffic
using this session is dropped.
check-new the CPU flags current sessions as persistent. Persistent sessions are not revalidated against new
firewall policy or routing changes. This reduces CPU load and packet loss. Firewall policy and routing changes only
apply to new sessions.
Only sessions created after setting firewall-session-dirty to check-new are flagged as persistent. Sessions
that existed before enabling check-new are not affected by this setting and are revalidated after a policy or routing
configuration change.
check-policy-option this option allows you to configure whether individual policies or routes are revalidated after a
policy or routing configuration change. For example:
config firewall policy
set firewall-session-dirty {check-all | check-new}
end
check-all enforces the latest firewall policy configuration and route updates for sessions,
optimizing security. check-new applies firewall policy and route change to new sessions only,
optimizing performance. You can use these options to balance security vs performance based
on your organization's priorities.
Performance monitoring
FortiGate supports multiple protocols for monitoring resource utilization, such as SNMPv3, NetFlow, and sFlow. These
protocols are used to measure the performance of the FortiGate and provide insight into the traffic that it is passing.
SNMP polling and traps can be used to optimize monitoring, and the results should be collected and consolidated into
meaningful output. A variety of third party SNMP reporting applications can be used to analyze collected results.
Resource monitoring helps to establish resource utilization baselines that can be useful for:
l Configuring IPS signature rates.
l Recognizing abnormal activity, such as when an attack is occurring.
l Comparing the bandwidth utilization over specific time spans, such as month to month or year to year, to plan for
growth.
l Comparing the bandwidth utilization between different WANs, and applying SD-WAN and traffic shaping as needed.
l Tuning security profiles to optimize resource usage.
Note that, when implementing MFA on the FortiGate, a FortiToken can only be registered to one FortiGate at a time. If
you use a remote authentication server for MFA, then each FortiGate points to the server. FortiAuthenticator and
FortiToken Cloud are remote authentication servers that can manage the FortiTokens for multiple FortiGates at the
same time. This allows you to use one token per user across multiple FortiGates.
Certificate usage
FortiOS leverages certificates in multiple areas, such as administrative access, ZTNA, SAML authentication, LDAPS,
VPNs, communication between Fortinet devices and services, deep packet inspection, and authenticating Security
Fabric devices.
The default Fortinet factory self-signed certificates are provided to simplify initial installation and testing. Replace any
used certificates with certificates that are signed by a trusted CA and specific to that FortiGate
Certificates can be uploaded to the FortiGate in multiple ways:
l Automated Certificate Management Environment (ACME),
l Simple Certificate Enrollment Protocol (SCEP),
l Uploading a certificate in the GUI or CLI,
l Creating a Certificate Signing Request (CSR), having it signed by a CA, then uploading the certificate.
Antivirus1 Protect external resources from malware, Scan requested user traffic for malware.
such as HTTP PUT requests or FTP uploads.
Web filter Not usually applied to inbound traffic. Monitor and block user web traffic based on
categories and domains.
Video filter Not usually applied to inbound traffic. Monitor and restrict YouTube videos based
on categories or channels.
DNS filter Not usually applied to inbound traffic. Monitor and filter DNS lookups based on
domain ratings.
Block requests for known compromised
domains.
Application control Make sure that specific protocols are used to Monitor and filter applications on any port.
access specific ports.
For example, only allow SSH traffic to be sent
and received over port 22.
Intrusion prevention Protect external services from known exploits Block connections to botnet sites.
and protocol anomalies.
File filter Prevent uploading files based on the file type Prevent downloading files based on the file
and the protocol that is used. type and the protocol that is used.
Email filter Perform spam detection and filtering. Prevent specific IP address or subnets from
sending and receiving email messages.
Block messages that contain specific words.
Data leak prevention Prevent sensitive data from entering your Prevent sensitive data, such as credit card
network. numbers or SSNs, from leaving your network.
VoIP Allow SIP and SCCP traffic, and protect your Secure clients that are connecting to external
network from SIP and SCCP based attacks. SIP servers.
Web application Detect and block known web application Not usually applied to outbound traffic.
firewall attacks, such as SQL injection, XSS, and
known exploits.
1
Antivirus profiles can submit files to FortiSandbox for further inspection. This enables the detection of zero-day
malware, and threat intelligence that is learned from submitted malicious and suspicious files supplements the
FortiGate’s antivirus database and protection.
In the case of Application Control, use the following to disable the use of replacement messages and port 8008:
config application list
edit <list>
set app-replacemsg disable
next
end
If it is acceptable to simply change the ports to a high ephemeral port, the override ports can be changed from here:
l Default:
config webfilter fortiguard
set ovrd-auth-port-http 8008
set ovrd-auth-port-https 8010
set ovrd-auth-port-https-flow 8015
set ovrd-auth-port-warning 8020
end
l Update:
config webfilter fortiguard
set ovrd-auth-port-http <high port>
set ovrd-auth-port-https <high port>
set ovrd-auth-port-https-flow <high port>
set ovrd-auth-port-warning <high port>
end
as a FortiAuthenticator or a Windows server with certificate services. For information about uploading a CA certificate
and private key for deep inspection, see Certificates in the FortiOS Administration Guide.
To implement seamless deep inspection, users must trust the certificate that is signed by the FortiGate, and there must
be certificate chain back to the trusted root CA that is installed on the user's endpoint. If the root certificate is not
installed, the user receives a certificate warning every time they access a website that is scanned by the FortiGate using
deep inspection. Administrators should provide the CA certificate to the end users if deep inspection will be used.
Users should be made aware that their communication is subject to these security measures, and that their privacy while
protected by a FortiGate that is performing deep inspection cannot be guaranteed. Performing deep inspection might be
undesirable when users are accessing certain web categories, such banking or personal health related sites. When
creating SSL/SSH inspection profiles that use full SSL inspection, the Finance and Banking, Health and Wellness, and
Personal Privacy categories are exempt from inspection by default. Administrators can customize these categories,
enable Reputable websites, and add individual addresses to the SSL exemptions as required.
This procedure describes how to replace existing FortiGate equipment by manually migrating the existing configuration
using the configuration files. This can be done if a FortiGate is being replaced with the same model or if a FortiGate
model is upgraded to a newer model.
Before starting, ensure that you have:
l Access to a plain text editor, such as Notepad++
l An admin administrator account with the super_admin security profile
1. Create a backup file of the existing configuration for the old FortiGate device. For details, see Configuration backups
and reset.
2. Upgrade the new FortiGate device to the same firmware version as the old FortiGate device. For details, see
Upgrading individual devices.
3. Create a backup file of the new FortiGate device.
4. Open the backup configuration files for both the old and new FortiGate device models, and replace the config-
version section of the first line of the old FortiGate configuration file with the config-version section of the new
FortiGate configuration file.
If the new and old FortiGate devices have the same model number, for example swapping
a FG-80 device with another FG-80 device, the first line in both configuration files should
be the same. If the new FortiGate device is a different model number from the old
FortiGate device, for example swapping a FG-80 device for a FG-100 device, update the
configuration version in the first line of the configuration file. For example:
#config-version=FGT80F-7.0.6-FW-build0366-
220606:opmode=0:vdom=0:user=admin
#config-version=FGT100F-7.0.6-FW-build0366-
220606:opmode=0:vdom=0:user=admin
5. Review the configuration file on the old FortiGate device, and edit the configuration file to ensure the rest of file
matches the interface layout for the new FortiGate device setup.
This step is only required when swapping a FortiGate device with a different model number
than the old FortiGate device, for example swapping a FG-80 device with a FG-100
device. If the FortiGate replacement device has the same model number, for example
swapping a FG-80 device with another FG-80 device, skip this step.
6. Restore the modified configuration file from the old FortiGate device into the new FortiGate device. Once the
configuration file is restored in the new FortiGate device, reboot the device.
7. Once the reboot is complete, review the error log for any import errors. If any errors are present, compare the two
configuration files from both the modified old FortiGate device and the new FortiGate device and correct the errors.
Use this command in the CLI to check for errors:
#diag debug config-error-log read
Once all errors are corrected, restore the modified configuration file into the new FortiGate device again and reboot
the device. Repeat this step until all errors are gone.
8. Once the device reboots with no errors, swap the cables from the old FortiGate device to the new FortiGate device.
Any FortiSwitch devices connected to the FortiGate should keep their previous configuration.
SSL VPN
Choosing a mode of operation and applying the proper levels of security depends on your specific environment and
requirements.
In tunnel mode, the SSL VPN client encrypts all traffic from the remote client computer and sends it to the FortiGate
through an SSL VPN tunnel over the HTTPS link between the user and the FortiGate. It supports a wide range of
applications, and provides a transparent user experience when properly configured. FortiClient might enable a DTLS
tunnel that allows the SSL VPN to encrypt traffic using TLS, and uses UDP as the transport layer instead of TCP. This
avoids retransmission issues that can occur with TCP-inTCP that result in lower throughput. For information on
troubleshooting slow SSL VPN throughput, see Troubleshooting common issues in the FortiOS Administration Guide.
Web mode provides clientless network access using a web browser with built-in SSL encryption. It is easier to set up
than tunnel mode and does not require that an application be installed on the endpoint, but it has limited application
support and requires more resources on the FortiGate.
For more information, see SSL VPN best practices in the FortiOS Administration Guide.
IPsec VPN
IPsec VPN is a standard protocol that allows a variety of solutions for endpoint connectivity, including FortiClient.
It is a well defined protocol that uses specific ports, and it is not uncommon for ISPs to block these ports. On the
FortiGate, administrators can configure the ports used for IKE (UDP 500 and 4500) (see Configurable IKE ports). IPsec
also has the option to accept a peer ID to specify a tunnel if several tunnels exist on the same interface.
For more information, see IPsec VPNs in the FortiOS Administration Guide.
High availability
HA provides resilience not only in the event of a cluster member failing, but also allows for firmware updates without any
downtime. Several HA options are supported by FortiGate: FortiGate Clustering Protocol (FGCP), FortiGate Session
Life Support Protocol (FGSP), Virtual Router Redundancy Protocol (VRRP), and auto scaling in cloud environments.
FGCP is the most commonly used HA solution. It allows two or more FortiGates of the same type and model to be put
into a cluster in Active-Passive (A-P) or Active-Active (A-A) mode. A-P mode provides redundancy by having one or
more FortiGates in hot standby in case the primary device experiences a detectable failure. If a failure occurs, traffic
quickly fails over to a secondary device, preventing any significant downtime. A-A mode allows traffic to be balanced
across the units in the cluster for scanning purposes, and also performs failover. For FortiGates on the network edge, at
least a two unit cluster is recommended.
FGSP is used in more advanced setups that include external load balancers that distribute traffic across the firewall
nodes. FGSP members do not need to have the same network configuration, so they do not need to be in the same
physical location. Each FGSP member usually has identical firewall policies to enforce the same access rules. Sessions
can be failed over from one FGSP member to another if a device failure occurs.
HA is supported on cloud and virtual platforms. In the cloud, HA can be configured in A-P, A-A load balancing, auto-
scaling, and others. See the FortiGate Public Cloud documentation for more information.
FortiGates also support VRRP. This can be an appropriate choice when interoperating with third party routers and
firewalls. Consult public documentation for further details.
Assess your environment and budget to determine what options are most appropriate for your use case.
along with FortiGate HA could be used so that no single link, switch, or firewall is a point of failure that could disrupt the
entire network. For information on FortiSwitch architectures that can deploy such redundancy, see the FortiSwitch
documentation.
SD-WAN
Traffic bottlenecks and disruptions often occur on the WAN links and ISP networks that are outside of your network
These can be due to bandwidth limitations, link quality, and other outside factors that are affecting your ISP. Using
multiple WAN connections from different vendors can ensure connectivity in the event of an ISP outage and increase
performance and throughput. SD-WAN SLA performance health checks can ensure that your WAN connection is always
available by selecting the next redundant WAN if the quality of the WAN link is degraded.
SD-WAN can also provide application and service based steering. For example, critical traffic can be steered to a more
expensive but more reliable transport link, while less important traffic is steered to a cheaper, higher bandwidth link. After
the rules have been defined, traffic steering happens automatically, with failover occurring as needed based on the link
health monitors. This can save administrative effort, and the panic caused be network outages, while providing a stable
experience for the end users.
For more information about SD-WAN solutions and configurations, see SD-WAN in the FortiOS Administration Guide.
Policies
The FortiGate's primary role is to secure your network and data from external threats. It accomplishes this using policies
and security profiles. Policies control what kind of traffic is allowed where, and security profiles define what to look for in
the traffic.
FortiGate also has an NGFW mode in which you can allow applications and URL categories directly in the policies, and
do not need to define security profiles.
Use the different policy types to secure the different types of traffic that the FortiGate processes.
DoS policies
DoS policies are checked before security policies to prevent attacks from overwhelming your network and FortiGate by
triggering more resource intensive security protection. These policies should be adjusted based on your business traffic
rates (see Performance monitoring on page 14).
Local-in policies
Local-in policies control access to the FortiGate interfaces. They are often used to block unauthorized access to
management ports or other well known ports, and to limit access from specific sources. They should be used to further
enable or restrict access to the FortiGate based on your security requirements.
Note that extra care should be taken when configuring a local-in policy, as an incorrect configuration could inadvertently
deny traffic for SSL VPN, dynamic routing protocols, HA, and other FortiGate features.
Security policies
l Security policies control the flow of traffic and the security features that are applied to the traffic flow. They are the
most commonly used policy type.
l Each policy should have a unique name and there should not be any unused policies.
l Policies that allow traffic should apply to a specific interface, and not the any interface.
l Only the security profiles that are necessary for the traffic matching policy should be enabled.
l Security policies are evaluated in order. When traffic matches a policy, further policies are not processed. Put the
most specific policies at the top of the list, and follow the least privilege access principle.
l Interface aliases
l It might not be possible to use the same interface on each FortiGate for the same function. Add aliases to the
interfaces so that policies are easier to understand. For example, a policy that controls traffic between you
network and your phones switch is clearer if it shows LAN to Phones, instead of port4 to port2.
l Zones
l Zones are used to group multiple interfaces or subinterfaces into a single interface object that can be used in
policies.
l Grouping interfaces and VLAN subinterfaces into zones simplifies security policy creation by allowing multiple
network segments to use the same policy settings and protection profiles.
l Interfaces in a zone can also still be used individually and still route normally.
l Policies
l Put the most specific, or narrow, policies at the top of the policy list.
l Do not use the all or any objects in a policy, except when routing to the internet.
l Do not override the implicit deny policy.
l Use users in policies. This makes the policy more specific and reduces the chances of unintended traffic
matching.
l To update or modify a policy that is actively passing traffic in a production environment, see Policy
configuration changes on page 13.
Virtual IPs
Policies that include VIPs, or that have match-vip enabled, have priority over other policies.
For example, with the following policies, where Policy 1 comes first in the list, and Policy 2 has a VIP for its destination:
Policy 1 Policy 2
Traffic from [Link] to the WEB_SERVER VIP is not blocked, because policy 2 takes priority because it uses a VIP.
If Policy 1 is edited to enable match-vip, then it will have a higher priority and traffic from [Link] to the WEB_
SERVER VIP will be blocked.
config firewall policy
edit 1
set match-vip enable
next
end
The match-vip command can only be enabled in DENY policies. it is not available in
ACCEPT policies.
VPN
The following VPNs are for connecting disparate sites to your LAN. See Remote access on page 26 for information
about remote user access. There are several was to establish VPN connections between FortiGates, and some that can
be applied to other VPN appliances.
OCVPN
OCVPN is a cloud-based solution to simplify IPsec VPN setup. It automatically generates the IPsec configuration,
including static routes and policies, on all of the FortiGates in the FortiCare account. It includes self-learning for updates
on a FortiGate, such as changing the public IP address in DHCP.
ADVPN
ADVPN is used in hub and spoke topologies. The hub tells two spokes how they can establish a tunnel between each
other, instead of routing traffic through the hub.
Site to site
Site to site VPNs are used for a single, secure connection between two sites, or between a site and a cloud service. The
connection can be to an external party, such as a contractor or MSSP, or within the same business, such as to connect a
remote site to the headquarters.
Physical security
Install the FortiGate in a physically secure location. Physical access to the FortiGate can allow it to be bypassed, or other
firmware could be loaded after a manual reboot.
If the FortiGate cannot be physical secured:
l Disable USB firmware and configuration installation:
config system auto-install
set auto-install-config disable
set auto-install-image disable
end
l Enable port security (802.1x) to prevent unauthorized devices from forwarding traffic.
l Optionally, disable the maintainer account. Note that doing this will make you unable to recover administrator
access using a console connection is all of the administrator credentials are lost.
Firmware
Keep the FortiOS firmware up to date. The latest patch release has the most fixed bugs and vulnerabilities, and should
be the most stable. Firmware is periodically updated to add new features and resolve important issues.
l Read the release notes. The known issues may include issues that affect your business.
l Do not use out of support firmware. Review the product lifecycle and plan to upgrade before the firmware expires.
Encrypted protocols
Use encrypted protocols whenever possible, for example:
l LDAPS instead of LDAP
l SNMPv3 instead of SNMP
l SSH instead of telnet
l OSPF MD5 authentication
l SCP instead of FTP or TFTP
l NTP authentication
l Encrypted logging instead of TCP
Strong ciphers
Force higher levels of encryption and strong ciphers:
config system global
set strong-crypto enable
set ssl-static-key-ciphers disable
set dh-params 8192
end
The ssh-hmac-md5 and ssh-cbc-cipher commands are removed in FortiOS 7.0.2 and
later. See Enabling individual ciphers in the SSH administrative access protocol for details.
FortiGuard databases
Ensure that FortiGuard databases, such as AS, IPS, and AV, are updated punctually. Optionally, send an alert if they are
out of date.
Penetration testing
Test your FortiGate to try to gain unauthorized access, or hire a penetration testing company to verify your work.
Denial of service
Denial of service (DoS) is a type of attack meant to disable a machine or network causing inaccessibility to the resource
or users. Most often this is accomplished by overwhelming the target with more information than it can handle, resulting
in a crash. DoS policies, which look for anomalous traffic patterns, are checked before the more resource intensive
security policies to help prevent this.
The following guidelines can be used to get started with DoS policies. These policies can be applied to incoming traffic
from your local network or internet, depending on your particular network.
l Enable anomaly logging and keep the action as monitor for some time. This is to observe and understand what
expected traffic looks like so that you may tune thresholds to have small margins, and therefore more protection.
Keep note of false alarms. If they are too frequent, you should adjust your policy accordingly.
l Enable the following DoS policy anomalies to help prevent targeted attacks:
l tcp_syn_flood
l tcp_port_scan
l tcp_src_session
l tcp_dst_session
l ip_src_session
l ip_dst_session
If you have an idea of your traffic rates for the preceding traffic patterns, you may adjust the threshold. Otherwise,
begin with the default and adjust after a period of observing normal traffic. For more information, see DoS protection
in the FortiOS Administration Guide.
l Where possible, enable ASIC DoS for offloading using network processor ASICs. The FortiOS Hardware
Acceleration Guide contains more information about DoS-related NP6 ASIC features, such as configuring NP6
anomaly protection and using the host protection engine (HPE) to protect the FortiGate from DoS attacks.
Configuration backup
The FortiGate configuration file has important information that should always be kept secured, including details about
your network, users, credentials, passwords, and keys. There are many reasons to back up your configuration, such as
disaster recovery, preparing for migrating to another device, and troubleshooting. Evaluate the risk involved if your
configurations were exposed, and manage your risk accordingly.
When backing up your configuration, consider the following steps to safeguard the file:
l Enable Encryption when backing up the configuration.
l Store the configuration file in a secure location.
l Delete old configuration files that are no longer needed.
If a configuration file must be shared with a third party for auditing, troubleshooting, or any other reasons, consider only
providing a section of the file and not the entire file. Otherwise, consider the following steps:
l Enable Encryption when backing up the configuration and only share the password with the intended party.
l Manually replace the passwords in the backed up configuration file.
l Request that the configuration file be deleted after the intended purpose has been satisfied.
Consider the following points when performing firmware upgrades, not only in FortiOS but as general rules for any
change you have to make in a production environment.
Never attempt to upgrade to a version that you do not fully understand, in terms of both
features and known limitations, and on which you have no operational experience.
Reasons to upgrade
You should have a valid reason for upgrading the firmware. The reason cannot be only because you want the latest
version. The reason has to be explained in terms of business, technical, or operational improvement.
Affirmative answers to the following questions are valid reasons to upgrade:
l Does the new version have a feature that helps to ensure compliance?
l Does the new version have an enhancement that allows a 40% decrease on the time it takes to perform a certain
operation?
l Does a new feature correct a known defect or bug found on a previous version that affects the company business or
operations?
l Will the new version allow your organization to deploy new services that will help to gain new customers or increase
loyalty of existing customers?
l Is the vendor cutting support for the version your organization is currently using?
If the best reason to upgrade is because the new features seem to be cool or because you want the latest version, some
more understanding and planning may be necessary.
l If your FortiGate is part of a security fabric, understand any firmware dependencies between fabric devices and plan
to upgrade fabric devices as necessary.
l Ensure you have a list of adjacent devices to the upgrading platform and have administrative access to them, in
case you need to do some troubleshooting. For example, if you are upgrading FortiWeb, make sure you can
administratively access the web applications. Likewise, if you are upgrading FortiGate, make sure you can
administratively access the surrounding switches and routers.
l Have a step-by-step plan on how to perform and test the upgrade. You want to make sure you think of the worst
situation before it happens, and have predefined courses of action, instead of thinking under pressure when
something has already gone wrong.
l Define a set of tests (that include critical business applications that should be working) to make sure the upgrade
was successful. If any test does not go well, define which ones mandate a rollback and which ones can be tolerated
for further troubleshooting. This set of tests should be run before and after the upgrade to compare results. The
tests performed before and after the upgrade should be the same.
l Define a clear rollback plan. If something goes wrong with the upgrade or the tests, the rollback plan will help you
get your environment back to a known and operational status. The plan must clearly state the conditions under
which the rollback will be started.
l Declare configuration freezes shortly before and after the upgrade. This reduces the amount of variables to take into
consideration if something goes wrong.
l Perform a quality assurance upgrade. Load a copy of the production configuration on a non-production box and
execute the upgrade to see if there are any issues on the process. Adjust your plan according to the results you
obtain.
l Have a list of information elements to be gathered if something goes wrong. This ensures that, even if the upgrade
fails, you will collect enough information to troubleshoot the issue without needing to repeat the problem. Get help
from Fortinet Support if you need to confirm what could be missing from your list.
l Define a test monitoring period after the change was completed. Even if the upgrade went smoothly, something
could still go wrong. Make sure that you monitor the upgraded system for at least one business cycle. Business
cycles may be a week, month, or quarter depending on your organization's business priorities.
l Enable your terminal emulation program to leave trace of all the commands executed and all the output generated.
If you are performing steps through the GUI, consider using a video capture tool to document it.
l Document any command or change performed over the adjacent and interdependent systems. Make sure they are
acknowledged by the relevant administrators.
l Document any deviations performed over the upgrade plan. This is the planned-versus-actual.
Changes on production IT infrastructure are critical to the business. Make sure they play in
your favor and not against you.
For details on upgrading and downgrading your device firmware, see the Firmware section and the Fabric Management
page of the FortiOS Administration Guide.
Copyright© 2025 Fortinet, Inc. All rights reserved. Fortinet®, FortiGate®, FortiCare® and FortiGuard®, and certain other marks are registered trademarks of Fortinet, Inc., and other Fortinet names herein
may also be registered and/or common law trademarks of Fortinet. All other product or company names may be trademarks of their respective owners. Performance and other metrics contained herein were
attained in internal lab tests under ideal conditions, and actual performance and other results may vary. Network variables, different network environments and other conditions may affect performance
results. Nothing herein represents any binding commitment by Fortinet, and Fortinet disclaims all warranties, whether express or implied, except to the extent Fortinet enters a binding written contract,
signed by Fortinet’s Chief Legal Officer, with a purchaser that expressly warrants that the identified product will perform according to certain expressly-identified performance metrics and, in such event, only
the specific performance metrics expressly identified in such binding written contract shall be binding on Fortinet. For absolute clarity, any such warranty will be limited to performance in the same ideal
conditions as in Fortinet’s internal lab tests. Fortinet disclaims in full any covenants, representations, and guarantees pursuant hereto, whether express or implied. Fortinet reserves the right to change,
modify, transfer, or otherwise revise this publication without notice, and the most current version of the publication shall be applicable.
When upgrading firmware on FortiGate devices, considerations include understanding the new version's features, limitations, and known issues. Planning should account for business impacts, ensuring the upgrade does not coincide with critical processes and securing management approval is vital. Technical factors include validating supported hardware models, assessing resource requirements, creating backups, and preparing rollback plans. The upgrade should be tested in non-production environments first. These considerations minimize disruption, maintain operational continuity, and ensure security enhancements are implemented effectively .
Applying the principle of least privilege in setting up LDAP connections on a FortiGate involves using LDAP credentials that have just enough permissions to accomplish necessary tasks, rather than full administrative rights. This reduces the risks of privilege escalation and data breaches. For secure LDAP connections, LDAPS should be used, and administrators are advised against regular bind operations with high privileges. Implementing these measures mitigates the risk of unauthorized access to sensitive information and enhances overall security .
Best practices for securing administrative access to a FortiGate device include reviewing and modifying default settings like administrator passwords, certificates, SSH keys, and firewall policies immediately upon deployment. Utilizing encrypted protocols such as SSH instead of telnet and implementing local-in policies for access control is also recommended. Physical security, disabling unnecessary services, and considering the implications of disabling the maintainer account for emergency recovery are essential steps. These measures help mitigate various threats such as unauthorized access and man-in-the-middle attacks .
NAT mode is recommended for environments where preserving internal network confidentiality is a priority, as it obscures internal IP addresses by translating them into a public-facing NATed IP address. This provides an additional layer of security by preventing external actors from directly accessing internal resources. Transparent mode, however, is suitable for complex networks where reconfiguration of IP addressing is not feasible. While it simplifies deployment in such scenarios, it does not provide the address obfuscation benefits of NAT, possibly leaving the network more exposed .
Recommended steps for physically securing a FortiGate device include installing it in a secure location to prevent unauthorized access or tampering. If physical security cannot be guaranteed, disabling USB installation ports and enabling 802.1x port security are advised. Disabling the maintainer account can prevent recovery if access is compromised. Inadequate physical security could allow malicious actors to bypass the device, load rogue firmware, or access network configurations, leading to potential system breaches and data loss .
Implementing a configuration freeze during a FortiGate firmware upgrade is significant because it reduces the number of variables and potential conflicts during the upgrade process. By halting configuration changes shortly before and after the upgrade, administrators can more easily identify issues that stem from the upgrade itself rather than concurrent changes to the system. This clarity simplifies troubleshooting and ensures that the focus remains on achieving a successful upgrade while mitigating risks associated with multi-tasking .
Fortinet's PSIRT advisories play a crucial role in maintaining the security of FortiGate devices by continually testing and gathering information on vulnerabilities and weaknesses. These advisories provide detailed descriptions of serious issues and recommended protective solutions. Regular monitoring of these advisories enables administrators to proactively address security flaws and keep systems patched and resilient against emerging threats. By incorporating these insights into security practices, organizations can effectively safeguard their FortiGate infrastructure .
Uniformly using either flow mode or proxy mode inspection across policies is recommended to optimize resource utilization. Flow mode prioritizes traffic throughput and uses fewer resources, making it suitable for high-throughput environments. Proxy mode, on the other hand, offers more thorough inspection at the cost of performance, making it ideal when security takes precedence over speed. While the throughput difference under normal conditions may be negligible, consistently applying one mode prevents performance variability and assists in troubleshooting and monitoring efficiency .
To register a new FortiGate device, one must register both the device and its service contract to gain full access to Fortinet Customer Service and support services. The registration can be performed through either the FortiGate GUI or the FortiCloud support portal. To validate the license status, navigate to System > FortiGuard on the FortiGate device and check the License Information table, which may take a few hours after registration to update. Ensure uninterrupted communication with FortiGuard and consult the FortiGuard troubleshooting section if updates are not received .
Certificate management in FortiOS enhances security by ensuring secure communication and authentication across various services, such as administrative access, deep packet inspection, and VPNs. Certificates are crucial for establishing trust between devices and services. Methods for certificate installation include using Automated Certificate Management Environment (ACME), Simple Certificate Enrollment Protocol (SCEP), uploading certificates via GUI or CLI, or creating a Certificate Signing Request (CSR), having it signed by a CA, and then uploading the certificate. These processes help maintain a robust security posture by ensuring only trusted communications occur .