From e1ede80d3b96daafe09aca9b98d4f82c3e5b410f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Caletka?= Date: Thu, 21 May 2015 16:24:56 +0200 Subject: [PATCH] eapol_test: Support IPv6 for authentication server MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This allows testing RADIUS servers over IPv6. Signed-off-by: Ondřej Caletka --- wpa_supplicant/eapol_test.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/wpa_supplicant/eapol_test.c b/wpa_supplicant/eapol_test.c index 983bbcdcc..bde7508b7 100644 --- a/wpa_supplicant/eapol_test.c +++ b/wpa_supplicant/eapol_test.c @@ -938,13 +938,12 @@ static void wpa_init_conf(struct eapol_test_data *e, *pos++ = a[3]; } #else /* CONFIG_NATIVE_WINDOWS or CONFIG_ANSI_C_EXTRA */ - if (inet_aton(authsrv, &as->addr.u.v4) < 0) { + if (hostapd_parse_ip_addr(authsrv, &as->addr) < 0) { wpa_printf(MSG_ERROR, "Invalid IP address '%s'", authsrv); assert(0); } #endif /* CONFIG_NATIVE_WINDOWS or CONFIG_ANSI_C_EXTRA */ - as->addr.af = AF_INET; as->port = port; as->shared_secret = (u8 *) os_strdup(secret); as->shared_secret_len = os_strlen(secret);