]> git.ipfire.org Git - thirdparty/hostap.git/commit
EAP-SIM peer: Fix counter-too-small message building
authorJouni Malinen <j@w1.fi>
Sun, 11 May 2014 14:54:59 +0000 (17:54 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 11 May 2014 14:57:28 +0000 (17:57 +0300)
commit04cad507e1521682a2d138217c3afd0b4ddcada5
treeb1cd0aeb01f9d6a53c1166f256d8ea772efd717e
parent32dca985c7320dc65699c993254d408e73ca874f
EAP-SIM peer: Fix counter-too-small message building

The extra data (nonce_s) used in this message was pointing to the
parsed, decrypted data and that buffer was previously freed just before
building the new message. This resulted in use of freed data and
possibly incorrect extra data value that caused the authentication
attempt to fail. Fix this by reordering the code to free the decrypted
data only after the new message has been generated. This was already the
case for EAP-AKA/AKA', but somehow missing from EAP-SIM.

Signed-off-by: Jouni Malinen <j@w1.fi>
src/eap_peer/eap_sim.c