Description |
This article describes Block ICMP timestamp on Fortigate interface while keeping ping enabled.
The ICMP timestamp response from Fortigate contains device's date and time. This information could be used as a vulnerability with high visibility.
To block ICMP timestamp request on wan1 interface IP, follow the below steps:
config system interface edit "wan1" set vdom "root" set ip 1.1.1.1 255.255.255.0 set allowaccess ping set type physical set snmp-index 1 next end |
Scope | FortiGate. |
Solution |
config firewall service custom edit "TIMESTAMP" set protocol ICMP set icmptype 13 next end
config firewall address edit "wan1-IP" set subnet 1.1.1.1 255.255.255.255 next end
config firewall local-in-policy edit 1 set intf "wan1" set srcaddr "all" set dstaddr "wan1-IP" set service "TIMESTAMP" set schedule "always" set action deny next end
Note that for the HA reserved management interface, need to add a dedicated command for the HA management interface. Refer to the guide below to configure the local-in policy for the dedicated reserved management interface: Technical Tip: How to configure a local-in policy on a HA reserved management interface
Testing the Policy Is Working:
In order to test the local-in policy is working as expected, use a tool such as hping3 to generate test traffic. https://linux.die.net/man/8/hping3
Example command:
Verify the local-in policy exists and note the policy index number:
diag firewall iprope list 100001
Example Output of hping3 test: Without local-in policy:
$ sudo hping3 1.2.3.4 --icmp --icmp-ts
With local-in policy enabled:
$ sudo hping3 1.2.3.4 --icmp --icmp-ts
Check Traffic Statistics:
diag firewall iprope show 100001 1 |
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.