]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Verify GAS fragmentation
authorJouni Malinen <jouni@qca.qualcomm.com>
Thu, 7 Nov 2013 22:15:17 +0000 (00:15 +0200)
committerJouni Malinen <j@w1.fi>
Thu, 7 Nov 2013 22:22:33 +0000 (00:22 +0200)
Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

tests/hwsim/test_gas.py

index 33ee72122890e55e6bb6b64f33019f16b7841c50..b0427735372840792b37f9dc11ed0297958da456 100644 (file)
@@ -179,3 +179,19 @@ def test_gas_concurrent_connect(dev, apdev):
         raise Exception("Operation timed out")
     if "CTRL-EVENT-CONNECTED" not in ev:
         raise Exception("Unexpected operation order")
+
+def test_gas_fragment(dev, apdev):
+    """GAS fragmentation"""
+    bssid = apdev[0]['bssid']
+    params = hs20_ap_params()
+    params['hessid'] = bssid
+    hostapd.add_ap(apdev[0]['ifname'], params)
+    hapd = hostapd.Hostapd(apdev[0]['ifname'])
+    hapd.set("gas_frag_limit", "50")
+
+    dev[0].scan()
+    dev[0].request("FETCH_ANQP")
+    for i in range(0, 6):
+        ev = dev[0].wait_event(["RX-ANQP"], timeout=5)
+        if ev is None:
+            raise Exception("Operation timed out")