]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Fix ap_acl_deny test
authorAyala Beker <ayala.beker@intel.com>
Tue, 23 Oct 2018 11:23:52 +0000 (14:23 +0300)
committerJouni Malinen <j@w1.fi>
Thu, 22 Nov 2018 13:53:30 +0000 (15:53 +0200)
In ap_acl_deny test, the AP doesn't send probe responses during scan due
to ACL reject. As the result, dev[0] might miss the AP's Beacon frame
because the dwell time is too short. Make the test more robust and
trigger passive scan, and by that increase the probability of hearing
the AP.

Signed-off-by: Ayala Beker <ayala.beker@intel.com>
tests/hwsim/test_ap_params.py

index 07088f82377963fc4ce2a72549fb1231f290f8a2..cd6846956da52d31a987cbc3422cc5575238cdb9 100644 (file)
@@ -150,7 +150,7 @@ def test_ap_acl_deny(dev, apdev):
     params['ssid'] = ssid
     params['deny_mac_file'] = "hostapd.macaddr"
     hapd = hostapd.add_ap(apdev[0], params)
-    dev[0].scan_for_bss(apdev[0]['bssid'], freq="2412")
+    dev[0].scan_for_bss(apdev[0]['bssid'], freq="2412", passive=True)
     dev[0].connect(ssid, key_mgmt="NONE", scan_freq="2412", wait_connect=False)
     dev[1].scan_for_bss(apdev[0]['bssid'], freq="2412")
     dev[1].connect(ssid, key_mgmt="NONE", scan_freq="2412")