mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-20 23:00:56 -05:00
- Fix #716: nodata proof with empty non-terminals and wildcards.
git-svn-id: file:///svn/unbound/trunk@3526 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
1ebcdeac38
commit
bdb24c91b2
2 changed files with 23 additions and 0 deletions
|
|
@ -1,5 +1,6 @@
|
||||||
29 October 2015: Wouter
|
29 October 2015: Wouter
|
||||||
- patch from Doug Hogan for SSL_OP_NO_SSLvx options.
|
- patch from Doug Hogan for SSL_OP_NO_SSLvx options.
|
||||||
|
- Fix #716: nodata proof with empty non-terminals and wildcards.
|
||||||
|
|
||||||
28 October 2015: Wouter
|
28 October 2015: Wouter
|
||||||
- Fix checklock testcode for linux threads on exit.
|
- Fix checklock testcode for linux threads on exit.
|
||||||
|
|
|
||||||
|
|
@ -340,6 +340,28 @@ int nsec_proves_nodata(struct ub_packed_rrset_key* nsec,
|
||||||
*wc = ce;
|
*wc = ce;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
/* See if the next owner name covers a wildcard
|
||||||
|
* empty non-terminal. */
|
||||||
|
while (dname_strict_subdomain_c(nm, nsec->rk.dname)) {
|
||||||
|
/* wildcard does not apply if qname below
|
||||||
|
* the name that exists under the '*' */
|
||||||
|
if (dname_subdomain_c(qinfo->qname, nm))
|
||||||
|
break;
|
||||||
|
/* but if it is a wildcard and qname is below
|
||||||
|
* it, then the wildcard applies. The wildcard
|
||||||
|
* is an empty nonterminal. nodata proven. */
|
||||||
|
if (dname_is_wild(nm)) {
|
||||||
|
size_t ce_len = ln;
|
||||||
|
uint8_t* ce = nm;
|
||||||
|
dname_remove_label(&ce, &ce_len);
|
||||||
|
if(dname_strict_subdomain_c(qinfo->qname, ce)) {
|
||||||
|
*wc = ce;
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
dname_remove_label(&nm, &ln);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Otherwise, this NSEC does not prove ENT and is not a
|
/* Otherwise, this NSEC does not prove ENT and is not a
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue