When receiving NSEC records via IXFR, the node was not marked with
havensec because the condition checked the uninitialized output
rdataset type instead of the input rdataset type. This caused
queries for empty non-terminal names in NSEC-signed zones received
via IXFR to return the zone apex NSEC instead of the correct
covering NSEC record.
The bug was introduced in
f4b4f030.
*/
options = DNS_DBADD_MERGE | DNS_DBADD_EXACT |
DNS_DBADD_EXACTTTL;
- if (!node->havensec && ardataset.type == dns_rdatatype_nsec) {
+ if (!node->havensec && rds->type == dns_rdatatype_nsec) {
nsec = qp;
}
result = qpzone_addrdataset_inner(