]> git.ipfire.org Git - thirdparty/hostap.git/commit
EAP-pwd server: Fix payload length validation for Commit and Confirm
authorJouni Malinen <j@w1.fi>
Fri, 1 May 2015 13:40:44 +0000 (16:40 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 3 May 2015 15:26:50 +0000 (18:26 +0300)
commite28a58be26184c2a23f80b410e0997ef1bd5d578
treecdacccaf9b4389175f719a78802151d115d7a244
parentdd2f043c9c43d156494e33d7ce22db96e6ef42c7
EAP-pwd server: Fix payload length validation for Commit and Confirm

The length of the received Commit and Confirm message payloads was not
checked before reading them. This could result in a buffer read
overflow when processing an invalid message.

Fix this by verifying that the payload is of expected length before
processing it. In addition, enforce correct state transition sequence to
make sure there is no unexpected behavior if receiving a Commit/Confirm
message before the previous exchanges have been completed.

Thanks to Kostya Kortchinsky of Google security team for discovering and
reporting this issue.

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