From f18b5542ad8b16d36e8bcb568b9b32960ff5006f Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sun, 14 Mar 2021 18:27:47 +0200 Subject: [PATCH] tests: OCV without PMF Signed-off-by: Jouni Malinen --- tests/hwsim/test_ocv.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tests/hwsim/test_ocv.py b/tests/hwsim/test_ocv.py index 42a4b1aaf..08e8ba20f 100644 --- a/tests/hwsim/test_ocv.py +++ b/tests/hwsim/test_ocv.py @@ -1190,3 +1190,15 @@ def test_wpa2_ocv_no_oci_workaround(dev, apdev): raise Exception("Could not set TEST_ASSOC_IE") dev[0].connect(ssid, psk=passphrase, scan_freq="2412", ocv="0", ieee80211w="1") + +def test_wpa2_ocv_without_pmf(dev, apdev): + """OCV without PMF""" + params = {"channel": "6", + "ieee80211n": "1", + "ieee80211w": "1", + "ocv": "1"} + hapd, ssid, passphrase = ocv_setup_ap(apdev[0], params) + hapd.disable() + hapd.set("ieee80211w", "0") + if "FAIL" not in hapd.request("ENABLE"): + raise Exception("OCV without PMF accepted")