TTLS: Fix peer challenge generation for TTLS/MSCHAPv2
authorJouni Malinen <jouni@qca.qualcomm.com>
Mon, 5 Mar 2012 14:59:03 +0000 (16:59 +0200)
committerJouni Malinen <j@w1.fi>
Mon, 5 Mar 2012 14:59:03 +0000 (16:59 +0200)
commite19467e1618854c0ebf4bb847fb38ad9cebbe083
tree78e45c7168b5d8360e9c15befe03d578427f4fe0
parentc8c340a9f639da0e6e5b0b126b43cce055ab8fc5
TTLS: Fix peer challenge generation for TTLS/MSCHAPv2

Commit 30680e9332c96803533b9dae6105fd7b15b5bb52 changed the length
of the implicit challenge result to match with the exact length used
in TTLS. However, it failed to update the peer_challenge generation
to use a separate random value. Previously, this was generated as
part of the implicit challenge, but more correct way would have been
to generate a random value for it separately. Do this now to fix the
read after the allocated buffer (16 bytes after the implicit
challenge).

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
intended-for: hostap-1
src/eap_peer/eap_ttls.c