From 0095461246cbec1d69e44f6df63ea0fc18234769 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Fri, 1 Nov 2024 12:24:34 +0200 Subject: [PATCH] tests: Update sae_password_id_pwe_looping to match implementation Now that hostapd was changed to explicitly reject attempts of using SAE password identifiers without H2E, this test case needs to be updated to not expect connection. Signed-off-by: Jouni Malinen --- tests/hwsim/test_sae.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tests/hwsim/test_sae.py b/tests/hwsim/test_sae.py index c119271c4..d5a7a2342 100644 --- a/tests/hwsim/test_sae.py +++ b/tests/hwsim/test_sae.py @@ -1896,9 +1896,12 @@ def test_sae_password_id_pwe_looping(dev, apdev): dev[0].set("sae_pwe", "3") dev[0].connect("test-sae", sae_password="secret", sae_password_id="pw id", - key_mgmt="SAE", scan_freq="2412") - if dev[0].get_status_field("ssid_verified") == "1": - raise Exception("Unexpected ssid_verified=1 in STATUS") + key_mgmt="SAE", scan_freq="2412", wait_connect=False) + ev = dev[0].wait_event(["CTRL-EVENT-SAE-UNKNOWN-PASSWORD-IDENTIFIER"], + timeout=10) + dev[0].request("DISCONNECT") + if ev is None: + raise Exception("Unknown password identifier not reported") finally: dev[0].set("sae_pwe", "0") -- 2.47.3