]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Run Suite B test cases with OpenSSL 1.1.0
authorJouni Malinen <j@w1.fi>
Sun, 2 Aug 2015 14:11:47 +0000 (17:11 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 2 Aug 2015 14:11:47 +0000 (17:11 +0300)
Signed-off-by: Jouni Malinen <j@w1.fi>
tests/hwsim/test_suite_b.py

index 7b3e90c164cbb50e5dd6ad417a179bde58124826..1a32c695156c4ae0788e9414d27d3cc793cd81d7 100644 (file)
@@ -18,10 +18,18 @@ def check_suite_b_capa(dev):
         raise HwsimSkip("BIP-GMAC-128 not supported")
     if "WPA-EAP-SUITE-B" not in dev[0].get_capability("key_mgmt"):
         raise HwsimSkip("WPA-EAP-SUITE-B not supported")
+    check_suite_b_tls_lib(dev)
+
+def check_suite_b_tls_lib(dev):
     tls = dev[0].request("GET tls_library")
     if not tls.startswith("OpenSSL"):
         raise HwsimSkip("TLS library not supported for Suite B: " + tls);
-    if "build=OpenSSL 1.0.2" not in tls or "run=OpenSSL 1.0.2" not in tls:
+    supported = False
+    for ver in [ '1.0.2', '1.1.0' ]:
+        if "build=OpenSSL " + ver in tls and "run=OpenSSL " + ver in tls:
+            supported = True
+            break
+    if not supported:
         raise HwsimSkip("OpenSSL version not supported for Suite B: " + tls)
 
 def test_suite_b(dev, apdev):
@@ -121,11 +129,7 @@ def check_suite_b_192_capa(dev):
         raise HwsimSkip("BIP-GMAC-256 not supported")
     if "WPA-EAP-SUITE-B-192" not in dev[0].get_capability("key_mgmt"):
         raise HwsimSkip("WPA-EAP-SUITE-B-192 not supported")
-    tls = dev[0].request("GET tls_library")
-    if not tls.startswith("OpenSSL"):
-        raise HwsimSkip("TLS library not supported for Suite B: " + tls);
-    if "build=OpenSSL 1.0.2" not in tls or "run=OpenSSL 1.0.2" not in tls:
-        raise HwsimSkip("OpenSSL version not supported for Suite B: " + tls)
+    check_suite_b_tls_lib(dev)
 
 def test_suite_b_192(dev, apdev):
     """WPA2/GCMP-256 connection at Suite B 192-bit level"""