mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-10-26 17:25:34 +03:00
commit
fc432c2314
@ -358,7 +358,7 @@ int dhcp6_option_parse_ia(DHCP6Option *iaoption, DHCP6IA *ia) {
|
||||
int r = 0, status;
|
||||
uint16_t opt;
|
||||
size_t iaaddr_offset;
|
||||
uint32_t lt_t1, lt_t2, lt_valid, lt_min = ~0;
|
||||
uint32_t lt_t1, lt_t2, lt_valid = 0, lt_min = UINT32_MAX;
|
||||
|
||||
assert_return(ia, -EINVAL);
|
||||
assert_return(!ia->addresses, -EINVAL);
|
||||
|
@ -788,7 +788,8 @@ static int client_parse_message(
|
||||
uint8_t *optval;
|
||||
be32_t iaid_lease;
|
||||
|
||||
if (len < sizeof(DHCP6Option) || len < sizeof(DHCP6Option) + be16toh(option->len))
|
||||
if (len < offsetof(DHCP6Option, data) ||
|
||||
len < offsetof(DHCP6Option, data) + be16toh(option->len))
|
||||
return -ENOBUFS;
|
||||
|
||||
optcode = be16toh(option->code);
|
||||
|
Loading…
Reference in New Issue
Block a user