From f5439acf6a7b5a298f82066ff0241899fed38216 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sat, 6 Mar 2021 12:10:29 +0200 Subject: [PATCH] tests: RELOAD_WPA_PSK failure Signed-off-by: Jouni Malinen --- tests/hwsim/test_ap_psk.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/hwsim/test_ap_psk.py b/tests/hwsim/test_ap_psk.py index 7b623af17..be6a88b2a 100644 --- a/tests/hwsim/test_ap_psk.py +++ b/tests/hwsim/test_ap_psk.py @@ -168,6 +168,11 @@ def test_ap_wpa2_psk_file_keyid(dev, apdev, params): check_disconnect(dev, [True, True, False]) + with open(psk_file, 'w') as f: + f.write('broken\n') + if "FAIL" not in hapd.request("RELOAD_WPA_PSK"): + raise Exception("RELOAD_WPA_PSK succeeded with invalid file") + @remote_compatible def test_ap_wpa2_psk_mem(dev, apdev): """WPA2-PSK AP with passphrase only in memory"""