]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: EAP-EKE rejection of unsupported DH groups 2 and 5
authorJouni Malinen <j@w1.fi>
Sat, 13 Apr 2019 09:20:24 +0000 (12:20 +0300)
committerJouni Malinen <j@w1.fi>
Sat, 13 Apr 2019 09:20:24 +0000 (12:20 +0300)
Signed-off-by: Jouni Malinen <j@w1.fi>
tests/hwsim/test_ap_eap.py

index c506fbc1b5e394c25cea8d0bd016684940577e89..8edf5a195455a03fbb51192d586800edc2dc883d 100644 (file)
@@ -2848,12 +2848,24 @@ def test_ap_wpa2_eap_eke(dev, apdev):
         if ev is None:
             raise Exception("EAP success timed out")
         dev[0].wait_connected(timeout=10)
+    dev[0].dump_monitor()
 
     logger.info("Test failed algorithm negotiation")
     dev[0].set_network_quoted(id, "phase1", "dhgroup=9 encr=9 prf=9 mac=9")
     ev = dev[0].wait_event(["CTRL-EVENT-EAP-FAILURE"], timeout=10)
     if ev is None:
         raise Exception("EAP failure timed out")
+    dev[0].dump_monitor()
+
+    logger.info("Test unsupported algorithm proposals")
+    dev[0].request("REMOVE_NETWORK all")
+    dev[0].dump_monitor()
+    eap_connect(dev[0], hapd, "EKE", "eke user", password="hello",
+                phase1="dhgroup=2 encr=1 prf=1 mac=1", expect_failure=True)
+    dev[0].request("REMOVE_NETWORK all")
+    dev[0].dump_monitor()
+    eap_connect(dev[0], hapd, "EKE", "eke user", password="hello",
+                phase1="dhgroup=1 encr=1 prf=1 mac=1", expect_failure=True)
 
     logger.info("Negative test with incorrect password")
     dev[0].request("REMOVE_NETWORK all")