mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-28 18:28:23 -05:00
EAP-IKEv2: Fix compilation warning
Fix signed/unsigned comparison compilation warning introduced in
08ef442
"EAP-IKEv2: Fix the payload parser".
Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
This commit is contained in:
parent
d10792199e
commit
281ff42a01
@ -263,7 +263,7 @@ int ikev2_parse_payloads(struct ikev2_payloads *payloads,
|
||||
}
|
||||
phdr = (const struct ikev2_payload_hdr *) pos;
|
||||
plen = WPA_GET_BE16(phdr->payload_length);
|
||||
if (plen < sizeof(*phdr) || plen > end - pos) {
|
||||
if (plen < sizeof(*phdr) || pos + plen > end) {
|
||||
wpa_printf(MSG_INFO, "IKEV2: Invalid payload header "
|
||||
"length %d", plen);
|
||||
return -1;
|
||||
|
Loading…
Reference in New Issue
Block a user