Quantifying DNSSEC Overhead
Cricket Liu (Infoblox)
I realized last week that I'd never actually traced all the queries sent and responses received by a recursive name server resolving a domain name in a zone signed with DNSSEC. I decided to trace the recursive resolution of an RRset in a signed top-level domain, since I wanted to see the "chain of trust" in action. I knew .org was signed and figured isc.org (the Internet Systems Consortium's domain) would probably already have a DS (Delegation Signer) record. Sure enough, a quick query using dig verified that:
% dig ds isc.org. +dnssec
I chose www.isc.org/IN/A as the RRset I'd look up.
I started by clearing the cache on my BIND name server (running BIND 9.7.0rc1), so that I could watch my name server query the .org name servers and see the records returned:
% sudo rndc flush
Then I fired up tcpdump to capture DNS traffic:
% sudo tcpdump -w www.isc.org.cap port 53
And then sent the query:
% dig www.isc.org. +dnssec
This turned out not to capture enough data when the responses were long, so I refined my tcpdump command by specifying the option "-s 4096". Then I found out I wasn't catching all fragments of really long responses, so I dumped the "port 53" argument (since fragments don't carry port information) and used Wireshark to filter out all the non-DNS traffic. Now I actually had a complete record of the queries my name server sent and the responses it received.
The results surprised me: I saw five queries and five resulting responses, when resolution of a domain name from an unsigned zone, such as www.cert.org, would usually require at most just three roundtrips. And, of course, the signed responses were much larger than most unsigned responses.
Here's a short comparison of resolution of www.isc.org and www.cert.org:

This isn't a perfect comparison--isc.org has four authoritative name servers, while cert.org only has two, which would make isc.org responses larger even without DNSSEC--but it gives you a sense of how much more traffic DNSSEC will use: In this case, over 6.5 times as much!
Now, not all resolutions of RRsets in signed zones will require this many roundtrips: Once our name server has validated the signature of www.isc.org's A record, as well as the public keys for isc.org and org, it'll cache those results. Still, even the individual response that contained www.isc.org's A record (Response 3) was a whopping 17 times as large as the response containing the address of www.cert.org, and that record's TTL is just ten minutes, so we might have to look it up frequently.
Of course, the workload involved in sending and receiving those UDP datagrams pales in comparison with all the hashing and decryption that needs to be done to validate the records received. Here's what those five responses contained:
- Response 1: 6 NS records, 6 A records, 6 AAAA records
- Response 2: 4 NS records, 2 DS records, 1 RRSIG record
- Response 3: 4 A records, 1 AAAA record, 4 NS records, 12 RRSIG records
- Response 4: 4 DNSKEY records, 14 RRSIG records, 4 NS records, 3 A records, 1 AAAA record,
- Response 5: 4 DNSKEY records, 2 RRSIG records, 6 NS records, 1 RRSIG record, 2 A records, 2 AAAA records
Now, some of these are duplicates, and some RRSIG records aren't needed in the validation process, but each RRSIG record requires one cryptographic hashing operation and one asymmetric encryption operation to check, and each DS record requires one cryptographic hashing operation to check. Compare that with the resolution of www.cert.org, which would require all of, er, zero hashing operations and no asymmetric encryption operations.
As a consequence, we should expect to see CPU overhead go up dramatically as our name servers start handling more DNSSEC-signed responses. After you configure validation, you'd be well advised to begin monitoring your name server's CPU utilization, too, so you aren't caught by surprise when your recursive name server pegs the processor.
Posted in DNSSEC | BIND |
13 comments
Jan 15, 2010 at 4:46 PM
I am not looking forward to a DNSSEC-enabled future since it puts a ton of burden on me and nobody will actually derive benefit from it.
Jan 15, 2010 at 9:57 PM
Nobody, David? That's a fairly extreme position. Why do you think nobody will benefit?
Jan 18, 2010 at 9:45 AM
I suppose the DNSSEC vendors will benefit. :-)
I don't think the real world will benefit because I have a hard time imagining anyone running a resolver that throws away unsigned answers. And if they don't throw them away, then the benefit of DNSSEC is moot.
Jan 18, 2010 at 10:05 AM
I'm not sure they'll have the choice. If you configure BIND with a trust anchor for, say, .org, it'll discard answers from .org or secure subzones of .org that don't validate. The administrator doesn't have the option of saying, "Go ahead and return answers that don't validate."
Jan 18, 2010 at 10:17 AM
Sometimes tells me the option to discard answers will be added quickly as soon as we have enough production traffic on DNSSEC since there are bound to be catastrophic key management mistakes that take down big zones or even entire TLDs.
Jan 18, 2010 at 10:18 AM
*Something (not sometimes) :-)
** And we've already seen these catastrophic mistakes, but since nobody uses DNSSEC, nobody cares.
Jan 18, 2010 at 10:27 AM
That's certainly a possibility (the part about the option being added--I agree that the key management mistake is likely, if not inevitable).
Jan 20, 2010 at 4:55 PM
So how do people feel about the possible DOS-amplification 'benefits' of this 'new' technology ?
Jan 20, 2010 at 9:22 PM
Of course it depends on which "people" you speak to, but this person feels that the "benefits" will outweigh the "costs."
Besides, mounting a DNS-based amplification attack is trivial today *without* DNSSEC.
Jan 22, 2010 at 3:23 PM
David, I am a bit surprised at your attitude toward DNSSEC. First, people have noticed the recent screw-ups as government agencies have scrambled to implement DNSSEC. This is particularly true in the EDU and GOV communities. Second, as someone who wants to get the benefits of signing my own zones, and one who is assuming some risk in doing so, I'd be pretty peeved if a big, clueful DNS provider like, say, OpenDNS didn't offer validation. I'd have to suggest that my users not use OpenDNS or any other DNS provider that doesn't validate. I really don't want to be in the business of doing that, but I also want to derive benefit from my signed zones.
Jan 22, 2010 at 3:26 PM
Michael,
We'll support it if there is demand, and I've always been consistent in saying that.
But I still think it's solving the wrong problems in painful ways.
I'd much rather see something less invasive like DNSCurve start to get adoption.
Jan 22, 2010 at 3:33 PM
DNScurve doesn't help me as a zone administrator because it solves the wrong problems. I want people know that my DNS information really is my information. DNS is a public database so I don't need encryption of DNS traffic. I think the zone-based solution is better than the server based solution that DNScurve provides. I do think ECC is good cryptography (and should be incorporated into DNSSEC to reduce the response sizes Cricket notices) and DNScurve is elegant, but it just isn't the right solution.
Jan 22, 2010 at 3:45 PM
Michael,
That may be true about DNSCurve attacking the wrong problem, though as a recursive provider, I find value in it, but then we're still not solving the right problems in the right way.