mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-10-28 11:55:23 +03:00
resolved: when synthesizing NODATA from cached NSEC bitmaps, honour CNAME/DNAME
When an RR type is not set in an NSEC, then the CNAME/DNAME types might still be, hence check them too. Otherwise we might end up refusing resolving of CNAME'd RRs if we cached an NSEC before.
This commit is contained in:
parent
2cd8727718
commit
3ba27cd339
@ -636,7 +636,9 @@ int dns_cache_lookup(DnsCache *c, DnsResourceKey *key, int *rcode, DnsAnswer **r
|
||||
*ret = NULL;
|
||||
*rcode = DNS_RCODE_SUCCESS;
|
||||
|
||||
return !bitmap_isset(nsec->nsec.types, key->type);
|
||||
return !bitmap_isset(nsec->nsec.types, key->type) &&
|
||||
!bitmap_isset(nsec->nsec.types, DNS_TYPE_CNAME) &&
|
||||
!bitmap_isset(nsec->nsec.types, DNS_TYPE_DNAME);
|
||||
}
|
||||
|
||||
log_debug("%s cache hit for %s",
|
||||
|
Loading…
Reference in New Issue
Block a user