Internet Systems Consortium BIND DNSSEC DNSKEY Extended Flags denial of service vulnerability
A crafted DNSKEY record with the legacy extended-flags bit set and no key material after it causes BIND to skip algorithm validation, leaving a key object with a NULL function table. When the resolver later uses that key for DNSSEC validation, the named process dereferences the NULL pointer and crashes, denying service to all clients.
Originally disclosed on Cisco Talos
A denial of service vulnerability exists in the DNSSEC DNSKEY Extended Flags functionality of BIND (version(s): 9.21.21). A specially crafted mirror domain can lead to a denial of service.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The algorithm validity check in frombuffer() is placed inside a condition that only runs when bytes remain in the buffer, so a DNSKEY with the extended-flags bit and no key data skips validation and yields a key whose function table entry is NULL.
Impact
A remote attacker who can serve a malicious zone can crash the named resolver process, causing denial of service for all clients relying on it.
What the attacker needed
Attacker controls an authoritative zone; resolver mirrors or validates that zone; DNSSEC validation enabled
The fix
The vendor says it has fixed the issue; the report recommends moving the algorithm check outside the remaining-length condition and adding a NULL check on the key function table.
How it was found
- Generate a signed zone containing a crafted DNSKEY with the extended-flags bit and an unassigned algorithm number.
- Run dnssec-verify against the crafted zone file to trigger the crash.
- Alternatively, start the rogue authoritative server serving the crafted zone.
- Configure named to mirror that zone from the rogue server.
- Start named and let it transfer the zone, which crashes the process during verification.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A DNS resolver checks the digital signatures that protect domain data, and it needs a key to do that. BIND accepted a malformed key that named an algorithm it does not support, and it never checked that the algorithm was valid because the record ended early. Later, when the resolver tried to use the key, it followed an empty pointer and the whole program crashed, so nobody using that resolver could look up names.
What is DoS?
A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.