From: Jouni Malinen Date: Fri, 17 Oct 2025 13:12:55 +0000 (+0300) Subject: tests: Authentication server and invalid clients file X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=29fa3e682d19d2640257d23c81fcffa2b893f093;p=thirdparty%2Fhostap.git tests: Authentication server and invalid clients file Signed-off-by: Jouni Malinen --- diff --git a/tests/hwsim/test_authsrv.py b/tests/hwsim/test_authsrv.py index e0665bcb2..268bb0762 100644 --- a/tests/hwsim/test_authsrv.py +++ b/tests/hwsim/test_authsrv.py @@ -260,3 +260,14 @@ def test_authsrv_unknown_client(dev, apdev): if ev is None: raise Exception("EAP not started") dev[0].request("REMOVE_NETWORK all") + +def test_authsrv_invalid_clients_file(dev, apdev, params): + """Authentication server and invalid clients file""" + conf = params['prefix'] + '.authsrv.conf' + with open(conf, 'w') as f: + f.write("1.2.3.4 foo\nfoo") + p = authsrv_params() + p["radius_server_clients"] = conf + hapd = hostapd.add_ap(apdev[0], p, no_enable=True) + if "FAIL" not in hapd.request("ENABLE"): + raise Exception("ENABLE did not fail")