A deep look at CVE-2015-5477 and how CloudFlare Virtual DNS customers are protected
Aug 4, 2015Filippo Valsorda

Summary
This post details a specific DNS exploit (CVE-2015-5477) in BIND9 that causes a crash due to a failed assertion when handling TKEY queries. It provides a deep dive into the vulnerable code, tracing the bug flow from the `dns_message_findname` function to the `dns_tkey_processquery` function. The post explains how a non-TKEY record in the EXTRA section, combined with a subsequent call to `dns_message_findname` without resetting the `name` pointer, triggers the assertion failure. It also highlights that Cloudflare's Virtual DNS customers were protected because their custom Go DNS server, RRDNS, sanitizes queries and does not relay EXTRA section records for TKEY queries.
More from the DNS Infrastructure & Naming Conventions trail
- The keys to the Internet change on October 11, 2026. Are you ready?
- 1.1.1.1 now supports post-quantum DNSSEC, all 2,420 bytes of it
- How we saved 100 terabytes of memory by optimizing 1.1.1.1’s DNS cache
- BGP ORIGIN attribute manipulation and its impact on the Internet
- Cloudflare Internal DNS is now generally available