aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2019-08-17 13:12:23 (GMT)
committerJouni Malinen <j@w1.fi>2019-08-17 13:18:33 (GMT)
commit8315c1ef5baa4ae0f462e005096d04d5ffdd74ed (patch)
tree6cd70656e56a342e1354cdcd3e7e4de764ffae8f
parent62af2b18f74dbb848cba31dcf5fa7db6863df4bd (diff)
downloadhostap-pending.zip
hostap-pending.tar.gz
hostap-pending.tar.bz2
tests: Vendor EAP method in Phase 2pending
Signed-off-by: Jouni Malinen <j@w1.fi>
-rw-r--r--tests/hwsim/auth_serv/eap_user.conf1
-rw-r--r--tests/hwsim/test_ap_eap.py24
-rw-r--r--tests/hwsim/test_eap.py11
3 files changed, 36 insertions, 0 deletions
diff --git a/tests/hwsim/auth_serv/eap_user.conf b/tests/hwsim/auth_serv/eap_user.conf
index 7feb255..a75bc3d 100644
--- a/tests/hwsim/auth_serv/eap_user.conf
+++ b/tests/hwsim/auth_serv/eap_user.conf
@@ -16,6 +16,7 @@
"pax.user@example.com" PAX 0123456789abcdef0123456789abcdef
"psk.user@example.com" PSK 0123456789abcdef0123456789abcdef
"vendor-test" VENDOR-TEST "foo"
+"vendor-test-2" VENDOR-TEST "foo" [2]
"osen@example.com" WFA-UNAUTH-TLS
"unauth-tls" UNAUTH-TLS
diff --git a/tests/hwsim/test_ap_eap.py b/tests/hwsim/test_ap_eap.py
index 2fc6925..c9d80c9 100644
--- a/tests/hwsim/test_ap_eap.py
+++ b/tests/hwsim/test_ap_eap.py
@@ -1898,6 +1898,14 @@ def run_ap_wpa2_eap_ttls_eap_sim_ext(dev, apdev):
wait_connect=False, scan_freq="2412")
run_ext_sim_auth(hapd, dev[0])
+def test_ap_wpa2_eap_ttls_eap_vendor(dev, apdev):
+ """WPA2-Enterprise connection using EAP-TTLS/EAP-vendor"""
+ params = hostapd.wpa2_eap_params(ssid="test-wpa2-eap")
+ hapd = hostapd.add_ap(apdev[0], params)
+ eap_connect(dev[0], hapd, "TTLS", "vendor-test-2",
+ anonymous_identity="ttls",
+ ca_cert="auth_serv/ca.pem", phase2="autheap=VENDOR-TEST")
+
def test_ap_wpa2_eap_peap_eap_sim(dev, apdev):
"""WPA2-Enterprise connection using EAP-PEAP/EAP-SIM"""
params = hostapd.wpa2_eap_params(ssid="test-wpa2-eap")
@@ -2178,6 +2186,13 @@ def test_ap_wpa2_eap_peap_eap_tls(dev, apdev):
private_key2="auth_serv/user.key")
eap_reauth(dev[0], "PEAP")
+def test_ap_wpa2_eap_peap_eap_vendor(dev, apdev):
+ """WPA2-Enterprise connection using EAP-PEAP/EAP-vendor"""
+ params = hostapd.wpa2_eap_params(ssid="test-wpa2-eap")
+ hapd = hostapd.add_ap(apdev[0], params)
+ eap_connect(dev[0], hapd, "PEAP", "vendor-test-2",
+ ca_cert="auth_serv/ca.pem", phase2="auth=VENDOR-TEST")
+
def test_ap_wpa2_eap_tls(dev, apdev):
"""WPA2-Enterprise connection using EAP-TLS"""
params = hostapd.wpa2_eap_params(ssid="test-wpa2-eap")
@@ -4063,6 +4078,15 @@ def test_ap_wpa2_eap_fast_prov(dev, apdev):
dev[0].wait_disconnected()
dev[0].dump_monitor()
+def test_ap_wpa2_eap_fast_eap_vendor(dev, apdev):
+ """WPA2-Enterprise connection using EAP-FAST/EAP-vendor"""
+ params = hostapd.wpa2_eap_params(ssid="test-wpa2-eap")
+ hapd = hostapd.add_ap(apdev[0], params)
+ eap_connect(dev[0], hapd, "FAST", "vendor-test-2",
+ anonymous_identity="FAST",
+ phase1="fast_provisioning=2", pac_file="blob://fast_pac",
+ ca_cert="auth_serv/ca.pem", phase2="auth=VENDOR-TEST")
+
def test_ap_wpa2_eap_tls_ocsp(dev, apdev):
"""WPA2-Enterprise connection using EAP-TLS and verifying OCSP"""
check_ocsp_support(dev[0])
diff --git a/tests/hwsim/test_eap.py b/tests/hwsim/test_eap.py
index 53af855..dfa5833 100644
--- a/tests/hwsim/test_eap.py
+++ b/tests/hwsim/test_eap.py
@@ -361,3 +361,14 @@ def test_eap_teap_errors2(dev, apdev):
ca_cert="auth_serv/ca.pem", phase2="auth=MSCHAPV2",
pac_file="blob://teap_pac", wait_connect=False)
wait_eap_proposed(dev[0], wait_trigger="GET_FAIL")
+
+def test_eap_teap_eap_vendor(dev, apdev):
+ """EAP-TEAP with inner EAP-vendor"""
+ check_eap_capa(dev[0], "TEAP")
+ check_eap_capa(dev[0], "VENDOR-TEST")
+ params = hostapd.wpa2_eap_params(ssid="test-wpa2-eap")
+ hapd = hostapd.add_ap(apdev[0], params)
+ eap_connect(dev[0], hapd, "TEAP", "vendor-test-2",
+ anonymous_identity="TEAP",
+ ca_cert="auth_serv/ca.pem", phase2="auth=VENDOR-TEST",
+ pac_file="blob://teap_pac")