]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: AP VLAN with WPA2-Enterprise and local file setting VLAN IDs
authorJouni Malinen <j@w1.fi>
Wed, 2 Jan 2019 21:50:35 +0000 (23:50 +0200)
committerJouni Malinen <j@w1.fi>
Wed, 2 Jan 2019 21:50:35 +0000 (23:50 +0200)
Signed-off-by: Jouni Malinen <j@w1.fi>
tests/hwsim/test_ap_vlan.py

index 76a53d8d1cce2aa609eec479b2636e21f9eabcea..62e1d32b1872112f0de4b9ca353d9c547d4e7f18 100644 (file)
@@ -156,6 +156,31 @@ def test_ap_vlan_wpa2_radius_2(dev, apdev):
 
     hwsim_utils.test_connectivity_iface(dev[0], hapd, "brvlan1")
 
+def test_ap_vlan_wpa2_radius_local(dev, apdev):
+    """AP VLAN with WPA2-Enterprise and local file setting VLAN IDs"""
+    params = hostapd.wpa2_eap_params(ssid="test-vlan")
+    params['dynamic_vlan'] = "0"
+    params['vlan_file'] = "hostapd.vlan"
+    params['vlan_bridge'] = "test_br_vlan"
+    params['accept_mac_file'] = "hostapd.accept"
+    hapd = hostapd.add_ap(apdev[0], params)
+
+    dev[0].connect("test-vlan", key_mgmt="WPA-EAP", eap="PAX",
+                   identity="pax.user@example.com",
+                   password_hex="0123456789abcdef0123456789abcdef",
+                   scan_freq="2412")
+    dev[1].connect("test-vlan", key_mgmt="WPA-EAP", eap="PAX",
+                   identity="pax.user@example.com",
+                   password_hex="0123456789abcdef0123456789abcdef",
+                   scan_freq="2412")
+    dev[2].connect("test-vlan", key_mgmt="WPA-EAP", eap="PAX",
+                   identity="pax.user@example.com",
+                   password_hex="0123456789abcdef0123456789abcdef",
+                   scan_freq="2412")
+    hwsim_utils.test_connectivity_iface(dev[0], hapd, "test_br_vlan1")
+    hwsim_utils.test_connectivity_iface(dev[1], hapd, "test_br_vlan2")
+    hwsim_utils.test_connectivity(dev[2], hapd)
+
 def test_ap_vlan_wpa2_radius_id_change(dev, apdev):
     """AP VLAN with WPA2-Enterprise and RADIUS attributes changing VLANID"""
     generic_ap_vlan_wpa2_radius_id_change(dev, apdev, False)