mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-20 23:00:56 -05:00
- Based on #1257: check parse limit before t increment in sldns RR
string parse routine. git-svn-id: file:///svn/unbound/trunk@4133 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
56bde1ceca
commit
619b808b31
2 changed files with 8 additions and 0 deletions
|
|
@ -1,3 +1,7 @@
|
|||
26 April 2017: Wouter
|
||||
- Based on #1257: check parse limit before t increment in sldns RR
|
||||
string parse routine.
|
||||
|
||||
24 April 2017: Wouter
|
||||
- unbound-checkconf -o allows query of dnstap config variables.
|
||||
Also unbound-control get_option. Also for dnscrypt.
|
||||
|
|
|
|||
|
|
@ -120,6 +120,10 @@ sldns_fget_token_l(FILE *f, char *token, const char *delim, size_t limit, int *l
|
|||
if (line_nr) {
|
||||
*line_nr = *line_nr + 1;
|
||||
}
|
||||
if (limit > 0 && (i >= limit || (size_t)(t-token) >= limit)) {
|
||||
*t = '\0';
|
||||
return -1;
|
||||
}
|
||||
*t++ = ' ';
|
||||
prev_c = c;
|
||||
continue;
|
||||
|
|
|
|||
Loading…
Reference in a new issue