mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-01-17 18:34:03 -05:00
tests: SELECT_NETWORK any
Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
6257f9c0da
commit
4bf1413ea9
@ -120,3 +120,20 @@ def test_ap_open_id_str(dev, apdev):
|
||||
raise Exception("CTRL-EVENT-CONNECT did not have matching id_str: " + ev)
|
||||
if dev[0].get_status_field("id_str") != "foo":
|
||||
raise Exception("id_str mismatch")
|
||||
|
||||
def test_ap_open_select_any(dev, apdev):
|
||||
"""AP with open mode and select any network"""
|
||||
hapd = hostapd.add_ap(apdev[0]['ifname'], { "ssid": "open" })
|
||||
id = dev[0].connect("unknown", key_mgmt="NONE", scan_freq="2412",
|
||||
only_add_network=True)
|
||||
dev[0].connect("open", key_mgmt="NONE", scan_freq="2412",
|
||||
only_add_network=True)
|
||||
dev[0].select_network(id)
|
||||
ev = dev[0].wait_event(["CTRL-EVENT-CONNECTED"], timeout=1)
|
||||
if ev is not None:
|
||||
raise Exception("Unexpected connection")
|
||||
|
||||
dev[0].select_network("any")
|
||||
ev = dev[0].wait_event(["CTRL-EVENT-CONNECTED"])
|
||||
if ev is None:
|
||||
raise Exception("Association with the AP timed out")
|
||||
|
Loading…
Reference in New Issue
Block a user