]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Add coverage for PASN authentication with KDK derivation
authorIlan Peer <ilan.peer@intel.com>
Thu, 8 Apr 2021 09:06:21 +0000 (12:06 +0300)
committerJouni Malinen <j@w1.fi>
Sat, 10 Apr 2021 08:55:55 +0000 (11:55 +0300)
Signed-off-by: Ilan Peer <ilan.peer@intel.com>
tests/hwsim/test_pasn.py

index bf9343833b03c203c58b7425c4dc639fbcd39e0b..150a21d01bcfaddea0a5ea91438bef7df19c5428 100644 (file)
@@ -803,3 +803,20 @@ def test_pasn_comeback_multi(dev, apdev):
             raise Exception("PASN: unexpected status")
 
         check_pasn_ptk(dev[i], hapd, "CCMP")
+
+def test_pasn_kdk_derivation(dev, apdev):
+    """PASN authentication with forced KDK derivation"""
+    check_pasn_capab(dev[0])
+
+    params = pasn_ap_params("PASN", "CCMP", "19")
+    hapd0 = start_pasn_ap(apdev[0], params)
+
+    params['force_kdk_derivation'] = "1"
+    hapd1 = start_pasn_ap(apdev[1], params)
+
+    try:
+        check_pasn_akmp_cipher(dev[0], hapd0, "PASN", "CCMP")
+        dev[0].set("force_kdk_derivation", "1")
+        check_pasn_akmp_cipher(dev[0], hapd1, "PASN", "CCMP")
+    finally:
+        dev[0].set("force_kdk_derivation", "0")