]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: More hostapd GET_CONFIG key_mgmt coverage
authorJouni Malinen <j@w1.fi>
Tue, 27 Dec 2016 17:24:34 +0000 (19:24 +0200)
committerJouni Malinen <j@w1.fi>
Wed, 28 Dec 2016 12:31:42 +0000 (14:31 +0200)
Signed-off-by: Jouni Malinen <j@w1.fi>
tests/hwsim/test_fils.py
tests/hwsim/test_suite_b.py

index 32d41ee5d223c4ed5f47b512035c35f2efa907ce..959bec3cc3e74cf9075536669c70b66abfa88c70 100644 (file)
@@ -65,6 +65,10 @@ def test_fils_sk_full_auth(dev, apdev):
         raise Exception("GTK rekey timed out")
     hwsim_utils.test_connectivity(dev[0], hapd)
 
+    conf = hapd.get_config()
+    if conf['key_mgmt'] != 'FILS-SHA256':
+        raise Exception("Unexpected config key_mgmt: " + conf['key_mgmt'])
+
 def test_fils_sk_sha384_full_auth(dev, apdev):
     """FILS SK full authentication (SHA384)"""
     check_fils_capa(dev[0])
@@ -109,6 +113,10 @@ def test_fils_sk_sha384_full_auth(dev, apdev):
         raise Exception("GTK rekey timed out")
     hwsim_utils.test_connectivity(dev[0], hapd)
 
+    conf = hapd.get_config()
+    if conf['key_mgmt'] != 'FILS-SHA384':
+        raise Exception("Unexpected config key_mgmt: " + conf['key_mgmt'])
+
 def test_fils_sk_pmksa_caching(dev, apdev):
     """FILS SK and PMKSA caching"""
     check_fils_capa(dev[0])
index e4531e823a817a72e319ca73f9f5447beaafa9ff..8fd4caeb16ee9f7bd8e62e39d4229483efe33568 100644 (file)
@@ -84,6 +84,10 @@ def test_suite_b(dev, apdev):
     if "CTRL-EVENT-EAP-STARTED" in ev:
         raise Exception("Unexpected EAP exchange")
 
+    conf = hapd.get_config()
+    if conf['key_mgmt'] != 'WPA-EAP-SUITE-B':
+        raise Exception("Unexpected config key_mgmt: " + conf['key_mgmt'])
+
 def suite_b_as_params():
     params = {}
     params['ssid'] = 'as'
@@ -187,6 +191,10 @@ def test_suite_b_192(dev, apdev):
     if "CTRL-EVENT-EAP-STARTED" in ev:
         raise Exception("Unexpected EAP exchange")
 
+    conf = hapd.get_config()
+    if conf['key_mgmt'] != 'WPA-EAP-SUITE-B-192':
+        raise Exception("Unexpected config key_mgmt: " + conf['key_mgmt'])
+
 def test_suite_b_192_radius(dev, apdev):
     """WPA2/GCMP-256 (RADIUS) connection at Suite B 192-bit level"""
     check_suite_b_192_capa(dev)