Created on
06-19-2020
03:25 AM
Edited on
10-27-2025
01:12 AM
By
Jean-Philippe_P
Description
This article describes that a brute force attempt (or attack) to the administrator account login is diagnosed by the following logs events, seen repetitively and/or in quantity (assuming Event log and Admin events are enabled):
Administrator root login failed from ssh(xxx.xxx.xxx.xxx) because of invalid user name.
After a few failed log messages, the following message will be seen:
Login disabled from IP xxxx for 60 seconds because of too many bad attempts.
In most cases, these logon attempts are generated by automatic hacker tools running on many compromised computers and scanning for live SSH targets to exploit known vulnerabilities or/and perform password brute force.
This article describes how to avoid this.
Scope
FortiGate.
Solution


Configure the local-in policy to block administrative access from attackers or malicious IPs trying to get into the FortiGate. To configure the local-in policy, follow the steps in Technical Tip: Use local-in policy to restrict unauthorized login attempts to administrative access ....
If admin access is limited strictly to the LAN interface, admin logins will still appear in the Security Event logs.
The local-in policy for the external interface is defined as follows:
config firewall local-in-policy
edit 1
set intf wan1
set srcaddr all
set dstaddr all
set action deny
set service HTTPS HTTP SSH
next
end
Note: Starting from FortiGate v7.6.0, the Local-in-Policy can also be configured in the GUI. Refer to this KB article: Technical Tip: Creating a Local-In policy (IPv4 and IPv6).
This will allow access only from within the network.
Implement Two-Factor Authentication to add an extra layer of security by requiring a second form of authentication. Follow the steps from this KB article: Technical Tip: How to activate FortiToken manually for admin account.
Related articles:
Technical Tip: How to delete or rename the default 'admin' user
Technical Tip: System administrator best practices
Technical Tip: Recommendations and common scenarios for Administrator access on FortiGate
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2025 Fortinet, Inc. All Rights Reserved.