From: Jouni Malinen Date: Tue, 1 Feb 2022 17:04:06 +0000 (+0200) Subject: tests: WPA2-PSK AP with PMF association comeback (using radio_disabled) X-Git-Tag: hostap_2_11~2267 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=bf4002e251c77ff16fe1fde4c751e4d9c41ffd36;p=thirdparty%2Fhostap.git tests: WPA2-PSK AP with PMF association comeback (using radio_disabled) Signed-off-by: Jouni Malinen --- diff --git a/tests/hwsim/test_ap_pmf.py b/tests/hwsim/test_ap_pmf.py index 6c2a58ac4..486ea1368 100644 --- a/tests/hwsim/test_ap_pmf.py +++ b/tests/hwsim/test_ap_pmf.py @@ -279,6 +279,31 @@ def test_ap_pmf_assoc_comeback2(dev, apdev): dev[0].p2p_interface_addr()) < 1: raise Exception("AP did not use reassociation comeback request") +@remote_compatible +def test_ap_pmf_assoc_comeback3(dev, apdev): + """WPA2-PSK AP with PMF association comeback (using radio_disabled)""" + drv_flags = dev[0].get_driver_status_field("capa.flags") + if int(drv_flags, 0) & 0x20 == 0: + raise HwsimSkip("Driver does not support radio_disabled") + ssid = "assoc-comeback" + params = hostapd.wpa2_params(ssid=ssid, passphrase="12345678") + params["wpa_key_mgmt"] = "WPA-PSK" + params["ieee80211w"] = "1" + hapd = hostapd.add_ap(apdev[0], params) + Wlantest.setup(hapd) + wt = Wlantest() + wt.flush() + wt.add_passphrase("12345678") + dev[0].connect(ssid, psk="12345678", ieee80211w="2", + key_mgmt="WPA-PSK", proto="WPA2", scan_freq="2412") + dev[0].set("radio_disabled", "1") + dev[0].set("radio_disabled", "0") + dev[0].request("REASSOCIATE") + dev[0].wait_connected(timeout=10, error="Timeout on re-connection") + if wt.get_sta_counter("assocresp_comeback", apdev[0]['bssid'], + dev[0].own_addr()) < 1: + raise Exception("AP did not use reassociation comeback request") + @remote_compatible def test_ap_pmf_assoc_comeback_wps(dev, apdev): """WPA2-PSK AP with PMF association comeback (WPS)"""