Response Rate Limiting (RRL)

Response Rate Limiting (RRL)

 RRL, or Response Rate Limiting, is a security feature implemented in DNS servers to mitigate the impact of Distributed Denial of Service (DDoS) attacks, particularly DNS amplification attacks. It works by limiting the rate at which DNS responses are sent from a server to a particular client or set of clients.

When a DNS server receives an unusually high volume of requests, possibly as part of an attack, RRL kicks in to restrict the number of responses sent back to any given requester over a specified period. This helps to prevent the server from being used as a tool in amplification attacks, where large numbers of responses are sent to a victim's network, overwhelming its bandwidth. It is implemented in ME DDI using the rate-limit DNS option.

 Configuring RRL in DDI 

 

To configure it select DNS-> Config-> DNS Options

On the DNS options page, click on the Options drop down box to search for rate-limit option.

The rate-limit option appears with all its attributes. Fill in the values for each attribute and click Save.


Here are explanations for various attributes of the rate-limit option:

  1. all-per-second: Limits the total number of all responses (regardless of type) per second.

  1. errors-per-second: Limits the number of error responses (like SERVFAIL) per second.

  1. ipv4-prefix-length and ipv6-prefix-length: Define the subnet mask length for aggregating IPv4 and IPv6 addresses. This dictates how broadly the rate limiting is applied across a range of IP addresses.
    For example, ipv4-prefix-length of 24 means that the server will apply rate limits to all addresses in each /24 subnet as a group. Therefore, all requests originating from the 192.168.1.0/24 subnet, for instance, would be collectively subject to the specified rate limit.

  1. exempt-clients: Specifies clients (usually by IP address or subnet) that are exempt from rate limiting. This is often used for trusted networks.

  1. log-only: When enabled, BIND logs the rate-limited responses without actually enforcing the limits. This is useful for testing the configuration.

  1. max-table-size: The maximum number of entries in the rate-limiting table. A larger table can track more clients but requires more memory.

  1. min-table-size: The minimum size of the rate-limiting table.

  1. nodata-per-second: Limits the number of responses per second that result in NODATA (no error but no data).

  1. nxdomains-per-second: Limits the number of NXDOMAIN (non-existent domain) responses per second.

  1. qps-scale: A factor by which to scale the queries per second calculation. It can be used to adjust the sensitivity of rate limiting.

  1. referrals-per-second: Limits the number of DNS referral responses per second.

  1. responses-per-second: Limits the number of identical responses per second from a single IP address or subnet.

  1. slip: Defines the behavior when a rate limit is exceeded. Typically, every nth response will be truncated.
    The slip setting determines how often the DNS server will send a truncated response instead of dropping the response entirely when rate limiting is in effect. A truncated response is a response that tells the querying client that it should retry the request over TCP instead of UDP. Since TCP connections require more resources to establish, attackers are less likely to use them, making DDoS attacks less effective.

Here’s a breakdown of the slip option:

  1. Value 0: The server will drop all responses that exceed the rate limit.

  1. Value 1: The server will send a truncated response for every request that exceeds the rate limit.

Values 2 and higher: The server will send truncated responses for one out of every 'slip' number of requests that exceed the rate limit. For example, if the slip value is set to 2, then the server will send a truncated response for every second request that exceeds the limit.

  1. window: The time period, in seconds, over which BIND calculates the rate of identical responses for rate limiting.

Example

rate-limit {

    responses-per-second 10;

    window 5;

    ipv4-prefix-length 24;

    ipv6-prefix-length 48;

    slip 2;

    nxdomains-per-second 5;

    nodata-per-second 5;

    errors-per-second 2;

    all-per-second 20;

    max-table-size 100000;

    exempt-clients { 192.168.0.0/24; };

    log-only yes;

};

 

 

From the above configuration example, ME DDI will limit identical DNS responses to 10 per second over a 5-seconds window. If the limit is exceeded, DDI will start sending truncated responses every second request (split=2). The local network (192.168.1.0/24) is exempt from these limits, and the log-only setting means the limits will be logged but not enforced, which is helpful for initial testing.

 

 

                  New to ADSelfService Plus?

                    • Related Articles

                    • 22. Configuring Response Rate Limiting (RRL) settings

                      Configuring DNS Response Rate Limiting (RRL) settings Response Rate Limiting (RRL) is a security feature designed to mitigate the impact of DNS amplification attacks by limiting the rate of responses a DNS server can send to a client. Configuring RRL ...
                    • Response rate limiting

                      Response Rate Limiting (RRL) RRL, or Response Rate Limiting, is a security feature implemented in DNS servers to mitigate the impact of Distributed Denial of Service (DDoS) attacks, particularly DNS amplification attacks. It works by limiting the ...
                    • Configuring Response Rate Limiting settings

                      Configuring DNS Response Rate Limiting (RRL) settings Response Rate Limiting (RRL) is a security feature designed to mitigate the impact of DNS amplification attacks by limiting the rate of responses a DNS server can send to a client. Configuring RRL ...
                    • Configuring Response Rate Limiting execution

                      Configuring RRL Exception List for Microsoft DNS Response Rate Limiting (RRL) helps mitigate the effects of DNS amplification attacks by limiting the rate at which responses are sent to clients. However, there might be certain clients or subnets that ...
                    • DNS Firewall(FRW) Response Policy Zones (RPZ)

                      RPZ (Response Policy Zone) allows a nameserver to modify DNS responses based on policies. It's often used for implementing security measures, such as blocking known malicious domains, redirecting domains, or applying other customized policies. When a ...