DNS Amplification Attack: Detection and Defense

A cybersecurity analyst monitors a network as a server is overwhelmed by a large flow of data.

Written by

in

You can stop a DNS amplification attack from using your servers by closing open recursion and rate limiting authoritative answers. You can blunt its impact on your network by coordinating upstream filtering before your link fills. The attack is a form of distributed denial of service (DDoS): it turns small, forged DNS questions into large answers aimed at someone else. That makes DNS a network security concern twice over, because your servers can be the weapon and your network can be the target.

A cybersecurity analyst monitors a network as a server is overwhelmed by a large flow of data.

To defend against a dns amplification attack, restrict recursive resolvers to your own clients, apply response rate limiting on authoritative servers, filter spoofed source addresses at your edge (BCP 38), and arrange upstream DDoS mitigation with your provider, because a victim cannot filter a flood that has already saturated its uplink.

PacketTools builds its free, no-login diagnostic tools from nearly three decades of production IT work, and the checks here are the same low-impact, authorized ones you can run on infrastructure you own. You will be able to tell whether you are a reflector or a target, and you will know which control fixes each case.

How Do Reflection and Amplification Overwhelm a Target?

A cybersecurity analyst monitors a flood of reflected network traffic overwhelming a server system.

The attack combines two tricks: reflection sends DNS answers to a forged victim address, and amplification makes each answer far bigger than the question that triggered it. UDP makes both possible because nothing confirms who sent a packet.

Reflection: Why Responses Reach a Spoofed IP Address

A DNS server answers whatever source address appears in the incoming packet. If an attacker forges that field with the victim’s address, the server faithfully replies to the victim, who never asked for anything.

The sequence runs in four steps: compromised machines send UDP packets with spoofed IP addresses to a DNS resolver, the resolver builds a large response, and the victim’s network absorbs it. The attacker stays hidden behind the reflectors, and the victim sees traffic from legitimate-looking DNS servers.

A botnet multiplies this. Thousands of bots each send modest query rates across many reflectors, so no single source looks alarming while the combined flood produces a denial-of-service.

Amplification: How Small Queries Produce Larger Responses

The amplification factor is the ratio of response size to request size. A 60-byte query that triggers a 4,000-byte response yields roughly 66x amplification, so every megabit the attacker spends lands as dozens on the victim.

Attackers pick queries that maximize the amplification effect. Requests that return many records at once, large TXT records, and DNSSEC-signed data all inflate answers. You can review which DNS record types your zones publish and how large they are.

DNS is not the worst protocol for this. Memcache has shown amplification sizes up to 51,200 times the requesting packet, which is why DNS is one reflection vector among several on your threat list.

Why UDP Enables Reflection Without a Connection Handshake

The user datagram protocol has no handshake. A server receives a datagram and replies, with no step that proves the sender owns the source address.

TCP’s three-way handshake blocks this pattern, since the forged party never completes the connection. Most attackers use UDP because the lack of a proper handshake makes spoofed reflection possible. The same distinction explains why defenses push suspicious clients toward TCP, and the trade-offs of DNS over TCP or UDP shape how rate limiting behaves.

Which DNS Server Roles Create Exposure?

A security analyst observes a vulnerable DNS server sending a large burst of data toward another network.

Open recursive resolvers are the largest source of exposure, but authoritative servers reflect traffic too, and DNSSEC makes both answers larger. The fix differs by role, so identify which role each server plays first.

Open Recursive Resolvers vs. Restricted Recursive Services

A dns resolver performs recursive lookups for clients. When it answers anyone on the internet, it becomes an open resolver, and attackers can aim it at any victim using any domain.

The scale of the problem has been large. CISA reported that of 27 million known DNS resolvers, approximately 25 million posed a significant threat of use in an attack. Many of those were consumer routers and forgotten servers with default settings.

A restricted recursive service answers only your address ranges. If your team is unsure where DNS recursion is enabled, start with an inventory: every VM, firewall, and branch router running a DNS service belongs on the list.

Why Authoritative DNS Servers Can Also Reflect Traffic

Authoritative servers must answer the whole internet for the zones they host, so you cannot close them. An attacker forges the victim’s address and asks for your own records, and your server replies as designed.

This is why a correctly configured authoritative server still participates in attacks. Rate limiting is the control here, because access lists would break public resolution. Keep authoritative and recursive functions on separate systems so each gets the right policy.

How DNSSEC and Response Size Affect Amplification

DNSSEC adds signatures to answers, and DNSKEY sets in particular produce large responses. That inflation is a side effect, and DNSSEC remains worth deploying for integrity.

You reduce the impact in your dns configuration by keeping TXT records lean and cleaning up stale entries. Servers can answer ANY queries minimally, as RFC 8482 allows, which removes one of the most abused large-answer paths.

How Can You Tell Whether You Are a Target or a Reflector?

Direction of traffic answers the question: victims receive floods of DNS responses they never requested, while reflectors send out floods of responses to addresses that never queried them. Flow data compared against a baseline separates both from ordinary demand.

Victim Indicators: Unsolicited Responses and Saturated Links

The clearest victim signal is dns response traffic arriving with source port 53 that matches no query your resolvers sent. CISA describes the main indicator as a query response without a matching request.

Other signs follow quickly:

  • Inbound UDP volume jumps while outbound DNS queries stay flat.
  • Many fragmented UDP packets appear, because large answers fragment.
  • Your uplink saturates and unrelated services slow down together.
  • Responses come from thousands of distinct DNS servers worldwide.

Reflector Indicators: Query Spikes and Excessive Outbound Responses

If you are the reflector, your servers show a surge in queries for the same name, often from one or a few apparent source addresses. Outbound bytes far exceed inbound bytes on UDP 53.

Check query logs for repeated identical questions and for requests from outside your client ranges on a resolver that should be internal. An open port checker run against your own public address shows whether port 53 is reachable when it should not be.

Distinguishing an Attack from DNS Failures and Legitimate Demand

Not every DNS spike is a ddos attack. A failing upstream, a misconfigured client retrying in a loop, or a marketing launch all raise volume.

Legitimate demand spreads across many names and clients and follows real user activity. Failures show timeouts and SERVFAIL responses with low byte counts. When resolution breaks and you are unsure why, the DNS server not responding pattern looks very different from a flood of large unsolicited answers.

Which Defenses Reduce Exposure and Attack Impact?

Four controls carry most of the weight: closed recursion on resolvers, response rate limiting (RRL) on authoritative servers, BCP 38 filtering at the network edge, and upstream scrubbing for inbound floods. The first three keep you from being a reflector; the last protects you as a victim.

Control Where it applies Main effect
Restricted recursion Recursive resolvers Removes you as an open amplifier
Response rate limiting Authoritative servers Caps repeated answers to one source
BCP 38 filtering Network edge, ISPs Drops forged source addresses
Upstream mitigation Provider or scrubbing network Absorbs floods before your link fills

Restrict Recursion to Authorized Clients

Turn recursion off entirely on authoritative-only servers. On internal resolvers, allow recursion only from your own address ranges using access control lists, such as BIND’s allow-recursion or Unbound’s access-control.

Microsoft DNS Server handles this differently. CISA notes it is not possible to restrict recursion to a client address range in that product, so the recommended pattern is an internal caching-only resolver behind a firewall, with authoritative service on a separate host with recursion disabled.

Apply Response Rate Limiting Without Breaking Legitimate DNS

RRL caps how many identical responses an authoritative server sends to one destination per second. Some limited answers become truncated replies so real clients retry over TCP, which forged sources cannot complete.

Start in log-only mode where your software supports it, watch which clients would be limited, then enforce. Large shared resolvers behind carrier NAT send heavy legitimate traffic, so set thresholds from your baseline, and keep RRL off recursive resolvers where it hurts performance.

Use BCP 38 Source Address Validation Where Traffic Originates

BCP 38 ingress filtering drops packets whose source address could not legitimately come from the interface where they entered. It stops spoofing at the source, which removes the root of every reflection attack.

Adoption remains uneven: a third of IPv4 autonomous systems allow or partially allow spoofing. If you run your own edge, enable unicast reverse path forwarding or egress ACLs so only your prefixes leave your network.

Coordinate Upstream Filtering and DDoS Mitigation with Your Provider

Once a flood fills your uplink, your own firewall cannot help because the congestion sits upstream of it. DDoS mitigation has to happen at your ISP or a scrubbing network.

Agree on the process before an incident: who to call, what evidence they need (flow samples, target IPs, timestamps), and whether they will filter UDP source port 53 toward you or announce a blackhole route. Hosting public DNS with an anycast provider spreads load across many sites. The threat persists: Azure mitigated 42,600 DNS reflected amplification attacks in 12 months.

How Can You Safely Check Your DNS Configuration?

Run passive record reviews with public tools, then test recursion only against servers you own or are authorized to assess, using low-volume queries. Never probe third-party servers for open recursion.

Review Public DNS Records with PacketTools DNS Lookup and SuperTool

PacketTools DNS Lookup shows what the internet sees for your zones, which helps you spot oversized TXT records, leftover verification strings, and records nobody can explain. The SuperTool runs DNS, MX, SPF, DKIM, DMARC, blacklist, and SSL tests in one pass.

Neither tool logs your IPs, queries, or test data, and no sign-in is required. If you prefer the command line, the nslookup command gives you the same record view from your own workstation.

Verify Recursion Restrictions Using Authorized, Low-Impact Queries

From a network your resolver policy should not trust (a cloud VM you control, for example), send a single query to your own resolver for a fresh name in a test zone whose authoritative logs you can read. A correctly restricted server returns REFUSED.

Do not trust the RA flag alone, because a cached answer can appear without real recursion. Check your authoritative logs: if the fresh name shows up there, your resolver recursed for an outside client and needs an ACL fix. Send one or two queries, never sustained volume.

Use the DNS Propagation Checker to Review Public Record Changes

After you trim records or change name servers, the DNS propagation checker shows whether resolvers worldwide see the new data. This confirms that cleanup removed large or stale records everywhere.

Watch TTLs. Old answers persist until caches expire, so a record you deleted can still appear for hours.

Recheck Access Controls and Service Health After Mitigation

Configuration changes can break legitimate resolution, especially ACLs that miss a VPN pool or a new branch subnet. Test from each client range after every change.

Confirm that internal users still resolve names, that RRL is not limiting busy partners, and that monitoring alerts on UDP 53 volume. If clients report failures, work through steps to troubleshoot DNS issues before rolling back the security control.

Keep DNS Useful Without Becoming a Reflector

You keep DNS useful and safe by matching each control to each server role. Recursive resolvers answer only your clients. Authoritative servers answer everyone but rate limit repeats and keep responses lean. Your edge drops forged source addresses.

For the victim side of dns amplification, your protection lives upstream, so settle contacts and evidence requirements with your provider in advance. On the network infrastructure side, schedule a quarterly check: single authorized recursion tests from an outside network, a record review for oversized entries, and a look at UDP 53 baselines for drift.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *