diff options
author | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2014-11-07 14:05:59 +0000 |
---|---|---|
committer | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2014-11-07 14:05:59 +0000 |
commit | e887c8718d124be600c83add78e0d76c9ef0afa9 (patch) | |
tree | 5a8e605a2ad6013b323b5c296873c9da570bb35d /sbin | |
parent | db3528d75b35ad3607d0751cc3fcac4ba5b31c79 (diff) |
Run eap_parse on the actual message and only when the length is right
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/iked/ikev2_pld.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sbin/iked/ikev2_pld.c b/sbin/iked/ikev2_pld.c index 951085f9d3e..f7e035b30df 100644 --- a/sbin/iked/ikev2_pld.c +++ b/sbin/iked/ikev2_pld.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ikev2_pld.c,v 1.45 2014/05/06 10:24:22 markus Exp $ */ +/* $OpenBSD: ikev2_pld.c,v 1.46 2014/11/07 14:05:58 mikeb Exp $ */ /* * Copyright (c) 2010-2013 Reyk Floeter <reyk@openbsd.org> @@ -1725,10 +1725,10 @@ ikev2_pld_eap(struct iked *env, struct ikev2_payload *pld, print_map(eap->eap_code, eap_code_map), eap->eap_id, betoh16(eap->eap_length), print_map(eap->eap_type, eap_type_map)); - } - if (eap_parse(env, sa, &hdr, msg->msg_response) == -1) - return (-1); + if (eap_parse(env, sa, eap, msg->msg_response) == -1) + return (-1); + } return (0); } |