Configuring a DNS Query Flood Protection policy
The DNS Query Flood Protection policy can limit the number of DNS request per second to mitigate against DNS query flood attacks.
A DNS query flood is a type of DDoS attack that targets the DNS server using DNS query and response traffic. A DNS query flood attack aims to overwhelm the target's resources with an excessive volume of fake requests, causing service unavailability and disrupting legitimate user access to the online service.
Using the DNS Query Flood Protection policy, you can set a DNS Query Rate Limit to restrict the number of queries that can be made per second. Once the query rate exceeds the limit, it will trigger a corresponding action (Pass or Deny).
After you have configured a DNS Query Flood Protection policy, you can apply it in a DoS Protection Profile.
To configure a DNS Query Flood Protection policy:
- Go to DoS Protection > Application.
- Click the DNS Query Flood Protection tab.
- Click Create New to display the configuration editor.
- Configure the following DNS Query Flood Protection settings:
Setting
Description
Name Specify a name for the DNS Query Flood Protection policy.
Valid characters areA
-Z
,a
-z
,0
-9
,_
, and-
. No spaces. The configuration name cannot be edited once it has been saved.Status Enable/disable the status of this DNS Query Flood Protection policy.
DNS Query Rate Limit Specify the allowable number of DNS requests per second. The range is 0 to 1048567. The default is 0, which means that no limit is placed on the number of DNS queries that can be made per second.
Note:
Multiple "rate limit" type of operations may be executed through various configurations, however, they cannot be executed all at once. Priority is given to certain rate limit operations. The following lists the execution sequence.Transaction Rate Limit (from the virtual server configuration).
DNS Query Rate Limit (from DNS Query Flood Protection policy).
ANY Query Rate Limit (from DNS Reverse Flood Protection policy).
Action Select the corresponding action to take when the DNS Query Rate Limit is exceeded:
Pass — Allow the traffic.
Deny — Drop the traffic, send a 400 Bad request to the client.
Deny is the default option.
Log Enable/disable logging for the Action. This is disabled by default. Severity Select the event severity to log when the DNS Query Flood Protection policy is triggered:
- High — Log as high severity events.
- Medium — Log as a medium severity events.
- Low — Log as low severity events.
The default is High.
-
Click Save.
After the new DNS Query Flood Protection policy has been saved, it will appear in the DNS Query Flood Protection page. You can now apply this DNS Query Flood Protection policy to a DoS Protection Profile configuration.
Statistical data of DNS Query Flood attacks are recorded in Security logs in detail (from FortiView and Log & Report), and in the Dashboard Security widget as event counts. Typically, Security logs provide the attack count as well, however, due to the speed at which DNS Query Flood attacks can occur (within milliseconds), the Security logs cannot accurately count each attack as the logs are counted every 1 second. This means that when a DNS Query Flood attack occurs, Security logs can only capture the attack details but not the accurate count of the number of packets that has exceeded the DNS Query Rate Limit. To view the correct count of each DNS Query Rate Limit excess event, you can reference the Security widget from the Dashboard that is a dedicated security event counter. |