mirror of
https://github.com/NLnetLabs/unbound.git
synced 2026-01-03 13:29:36 -05:00
- Fix wrong response ttl for prepended short CNAME ttls, this would
create a wrong zero_ttl response count with serve-expired enabled.
This commit is contained in:
parent
ab53baa6f5
commit
9f0b260c49
2 changed files with 6 additions and 0 deletions
|
|
@ -5,6 +5,8 @@
|
|||
- oss-fuzz badge on README.md.
|
||||
- Fix fix for #78 to also free service callback struct.
|
||||
- Fix for oss-fuzz build warning.
|
||||
- Fix wrong response ttl for prepended short CNAME ttls, this would
|
||||
create a wrong zero_ttl response count with serve-expired enabled.
|
||||
|
||||
11 September 2019: Wouter
|
||||
- Use explicit bzero for wiping clear buffer of hash in cachedb,
|
||||
|
|
|
|||
|
|
@ -409,6 +409,8 @@ iter_prepend(struct iter_qstate* iq, struct dns_msg* msg,
|
|||
num_an = 0;
|
||||
for(p = iq->an_prepend_list; p; p = p->next) {
|
||||
sets[num_an++] = p->rrset;
|
||||
if(ub_packed_rrset_ttl(p->rrset) < msg->rep->ttl)
|
||||
msg->rep->ttl = ub_packed_rrset_ttl(p->rrset);
|
||||
}
|
||||
memcpy(sets+num_an, msg->rep->rrsets, msg->rep->an_numrrsets *
|
||||
sizeof(struct ub_packed_rrset_key*));
|
||||
|
|
@ -421,6 +423,8 @@ iter_prepend(struct iter_qstate* iq, struct dns_msg* msg,
|
|||
msg->rep->ns_numrrsets, p->rrset))
|
||||
continue;
|
||||
sets[msg->rep->an_numrrsets + num_an + num_ns++] = p->rrset;
|
||||
if(ub_packed_rrset_ttl(p->rrset) < msg->rep->ttl)
|
||||
msg->rep->ttl = ub_packed_rrset_ttl(p->rrset);
|
||||
}
|
||||
memcpy(sets + num_an + msg->rep->an_numrrsets + num_ns,
|
||||
msg->rep->rrsets + msg->rep->an_numrrsets,
|
||||
|
|
|
|||
Loading…
Reference in a new issue