diff options
author | Eivind Næss <eivnaes@yahoo.com> | 2022-02-03 14:28:22 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-04 09:28:22 +1100 |
commit | d7e62a8499c4032d79e05afbd8fd3efd51c5b148 (patch) | |
tree | 46d612f2a36aca11557196ce1266b18d0aa25f68 /pppd/eap.c | |
parent | c2881a6b71a36d28a89166e82820dc5e711fd775 (diff) | |
download | ppp-d7e62a8499c4032d79e05afbd8fd3efd51c5b148.tar.gz |
pppd/eap: Fix bug causing incorrect response length (#334)
Need to update the esp->ea_client.ea_namelen variable. A plugin can override the
name of the user, and the variable is passed onto the eap_chap2_response generating
the wrong response length.
Signed-off-by: Eivind Næss <eivnaes@yahoo.com>
Diffstat (limited to 'pppd/eap.c')
-rw-r--r-- | pppd/eap.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -2182,6 +2182,7 @@ eap_request(eap_state *esp, u_char *inp, int id, int len) eap_send_nak(esp, id, EAPT_SRP); break; } + esp->es_client.ea_namelen = strlen(esp->es_client.ea_name); /* Create the MSCHAPv2 response (and add to cache) */ unsigned char response[MS_CHAP2_RESPONSE_LEN+1]; // VLEN + VALUE |