]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Fix wnm_action_proto_no_pmf to have active WNM_SLEEP operation
authorJouni Malinen <j@w1.fi>
Fri, 22 Sep 2017 08:32:30 +0000 (11:32 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 15 Oct 2017 23:03:47 +0000 (02:03 +0300)
The previous designed worked since wpa_supplicant did not track pending
request state. With such tracking added, this test case needs to make
sure there is a pending operation when injecting the invalid response.

Signed-off-by: Jouni Malinen <j@w1.fi>
tests/hwsim/test_wnm.py

index eeb2350499caa5ed975441853681ca1b2b69ab56..15f75c382e3e6f5ab7c6507551b18945f83a5ccb 100644 (file)
@@ -1488,6 +1488,11 @@ def test_wnm_action_proto_no_pmf(dev, apdev):
     dev[0].request("WNM_SLEEP enter")
     time.sleep(0.1)
     hapd.set("ext_mgmt_frame_handling", "1")
+    hapd.dump_monitor()
+    dev[0].request("WNM_SLEEP exit")
+    ev = hapd.wait_event(['MGMT-RX'], timeout=5)
+    if ev is None:
+        raise Exception("WNM-Sleep Mode Request not seen")
 
     msg = {}
     msg['fc'] = MGMT_SUBTYPE_ACTION << 4