When we get a bogus hostname in an option, drop the option rather than
refusing the lease. This allow obtaining leases on misadministered networks that use host names with underscores in them. MFC After: 3 days
This commit is contained in:
parent
6bb2e70696
commit
3354610e7d
@ -2252,6 +2252,8 @@ check_option(struct client_lease *l, int option)
|
||||
if (!res_hnok(sbuf)) {
|
||||
warning("Bogus Host Name option %d: %s (%s)", option,
|
||||
sbuf, opbuf);
|
||||
l->options[option].len = 0;
|
||||
free(l->options[option].data);
|
||||
return (0);
|
||||
}
|
||||
return (1);
|
||||
@ -2260,7 +2262,8 @@ check_option(struct client_lease *l, int option)
|
||||
if (!check_search(sbuf)) {
|
||||
warning("Bogus domain search list %d: %s (%s)",
|
||||
option, sbuf, opbuf);
|
||||
return (0);
|
||||
l->options[option].len = 0;
|
||||
free(l->options[option].data);
|
||||
}
|
||||
}
|
||||
return (1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user