Hi On Monday 18 February 2013, Matthew Newton wrote: [...] > The wpa_supplicant package contains a really useful tool, > eapol_test. It is not currently packaged, and it would be great if > this could be. Use of this, for example, often comes up on the > FreeRADIUS mailing list for RADIUS administrators to test their > EAP configuration. > > It's fairly easy to build from source, but our use case has it > installed on all our RADIUS servers for system monitoring. In this > case, having it packaged would make things much easier to deploy > and maintain. > > It doesn't build by default, and is generally only of interest to > administrators, so probably is not worth putting in the > wpasupplicant package, although that would be an option. > > I've created two small patches to the build system (for > squeeze/0.6.10-2.1 and unstable/1.0-3) that build eapol_test and > create a new 'eapoltest' package. > > Please would you consider adding this? [...]
At the moment, as of wpa_supplicant 1.1, this causes too many build problems, e.g. right now (after fixing the first one), I'm at: cc -c -o ../src/rsn_supp/wpa_ie.o -g -O2 -fPIE -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -MMD -Wall -D_FORTIFY_SOURCE=2 -I../src -I../src/utils -Werror -DEAPOL_TEST -DCONFIG_BACKEND_FILE -DCONFIG_IEEE80211W -DCONFIG_IEEE80211R -DCONFIG_PEERKEY -DCONFIG_IBSS_RSN -DCONFIG_P2P -DCONFIG_INTERWORKING -DCONFIG_DRIVER_WIRED -DCONFIG_DRIVER_NL80211 -DCONFIG_LIBNL20 `pkg-config --cflags libnl-3.0` -DCONFIG_DRIVER_NONE -DCONFIG_DRIVER_WEXT -DCONFIG_WIRELESS_EXTENSION -DEAP_TLS -DEAP_PEAP -DEAP_TTLS -DEAP_MD5 -DEAP_MSCHAPv2 -DEAP_GTC -DEAP_OTP -DEAP_SIM -DEAP_LEAP -DEAP_PSK -DEAP_AKA -DEAP_AKA_PRIME -DEAP_FAST -DEAP_PAX -DEAP_SAKE -DEAP_GPSK -DEAP_GPSK_SHA256 -DEAP_PWD -DCONFIG_WPS2 -DCONFIG_WPS -DEAP_WSC -DCONFIG_WPS_ER -DCONFIG_WPS_UPNP -DCONFIG_WPS_REG_DISABLE_OPEN -DEAP_IKEV2 -DEAP_TNC -DIEEE8021X_EAPOL -DCONFIG_AP -DCONFIG_NO_RADIUS -DCONFIG_NO_ACCOUNTING -DCONFIG_NO_VLAN -DEAP_SERVER -DEAP_SERVER_IDENTITY -DCONFIG_IEEE80211N -DNEED_AP_MLME -DEAP_SERVER_WSC -DCONFIG_NO_RADIUS -DPCSC_FUNCS -I/usr/include/PCSC -DPKCS12_FUNCS -DCONFIG_SMARTCARD -DCONFIG_TLSV11 -DEAP_TLS_OPENSSL -DCONFIG_SHA256 -DALL_DH_GROUPS -DCONFIG_CTRL_IFACE -DCONFIG_CTRL_IFACE_UNIX -DCONFIG_CTRL_IFACE_DBUS -DDBUS_API_SUBJECT_TO_CHANGE -I/usr/include/dbus-1.0 -I/usr/lib/i386-linux-gnu/dbus-1.0/include -DCONFIG_CTRL_IFACE_DBUS_NEW -DCONFIG_CTRL_IFACE_DBUS_INTRO -I/usr/include/dbus-1.0 -I/usr/lib/i386-linux-gnu/dbus-1.0/include -DCONFIG_DBUS -DCONFIG_SME -DCONFIG_DEBUG_SYSLOG -DLOG_HOSTAPD="LOG_DAEMON" -DCONFIG_DEBUG_FILE -DCONFIG_DELAYED_MIC_ERROR_REPORT -DCONFIG_BGSCAN_SIMPLE -DCONFIG_BGSCAN -DCONFIG_GAS -DCONFIG_OFFCHANNEL ../src/rsn_supp/wpa_ie.c ../src/utils/wpa_debug.c: In function '_wpa_hexdump': ../src/utils/wpa_debug.c:196:10: error: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'size_t' [-Werror=format=] title, len, display); with CONFIG_EAPOL_TEST=y enabled, another problem is the missing manpage for the eapoltest binary. The number of (trivial) build problems however indicates that this build target is barely tested upstream. I will revisit this once we've switched to wpa 2.1 (very soon), but won't make any promises yet; an updated and slightly fixed variant of your patch is attached. Regards Stefan Lippers-Hollmann
Index: debian/config/wpasupplicant/kfreebsd =================================================================== --- debian/config/wpasupplicant/kfreebsd (revision 1858) +++ debian/config/wpasupplicant/kfreebsd (working copy) @@ -223,7 +223,7 @@ CONFIG_PCSC=y # Development testing -#CONFIG_EAPOL_TEST=y +CONFIG_EAPOL_TEST=y # Select control interface backend for external programs, e.g, wpa_cli: # unix = UNIX domain sockets (default for Linux/*BSD) Index: debian/config/wpasupplicant/linux =================================================================== --- debian/config/wpasupplicant/linux (revision 1858) +++ debian/config/wpasupplicant/linux (working copy) @@ -222,7 +222,7 @@ CONFIG_PCSC=y # Development testing -#CONFIG_EAPOL_TEST=y +CONFIG_EAPOL_TEST=y # Select control interface backend for external programs, e.g, wpa_cli: # unix = UNIX domain sockets (default for Linux/*BSD) Index: debian/control =================================================================== --- debian/control (revision 1858) +++ debian/control (working copy) @@ -96,3 +96,12 @@ association with IEEE 802.11i networks. . This is a udeb of wpasupplicant for use by the debian-installer. + +Package: eapoltest +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: EAPoL testing utility + eapol_test allows testing EAP authentication methods without using + a full 802.1X connection. It is frequently used to test the EAP + configuration of RADIUS systems. It is an administrator tool and not + required for standard 802.1X authentication. Index: debian/eapoltest.install =================================================================== --- debian/eapoltest.install (revision 0) +++ debian/eapoltest.install (working copy) @@ -0,0 +1 @@ +wpa_supplicant/eapol_test usr/bin/ Index: debian/patches/P2P_remove-unused-variable.patch =================================================================== --- debian/patches/P2P_remove-unused-variable.patch (revision 0) +++ debian/patches/P2P_remove-unused-variable.patch (working copy) @@ -0,0 +1,36 @@ +From 78039295e6c53d9fa6a9bc81a65a123594c627f8 Mon Sep 17 00:00:00 2001 +From: Masashi Honma <masashi.ho...@gmail.com> +Date: Sat, 21 Apr 2012 18:21:30 +0300 +Subject: [PATCH 189/370] P2P: Remove unused variable + +The "type" variable is not used in wpas_p2p_deinit_global(). +So this patch removes it. + +Signed-hostap: Masashi Honma <masashi.ho...@gmail.com> +--- + wpa_supplicant/p2p_supplicant.c | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c +index d5c862c..bdfaecc 100644 +--- a/wpa_supplicant/p2p_supplicant.c ++++ b/wpa_supplicant/p2p_supplicant.c +@@ -2503,7 +2503,6 @@ void wpas_p2p_deinit_global(struct wpa_global *global) + while (wpa_s && wpa_s->p2p_group_interface != NOT_P2P_GROUP_INTERFACE) + wpa_s = wpa_s->next; + while (wpa_s) { +- enum wpa_driver_if_type type; + tmp = global->ifaces; + while (tmp && + (tmp == wpa_s || +@@ -2512,7 +2511,6 @@ void wpas_p2p_deinit_global(struct wpa_global *global) + } + if (tmp == NULL) + break; +- type = wpas_p2p_if_type(tmp->p2p_group_interface); + /* Disconnect from the P2P group and deinit the interface */ + wpas_p2p_disconnect(tmp); + } +-- +1.9.0 + Index: debian/patches/series =================================================================== --- debian/patches/series (revision 1858) +++ debian/patches/series (working copy) @@ -8,3 +8,4 @@ wpa_gui_desktop_add-keywords-entry.patch hostapd_fix-WDS-VLAN-bridge-handling.patch fix-spelling-s-algorith-algorithm.patch +P2P_remove-unused-variable.patch Index: debian/rules =================================================================== --- debian/rules (revision 1858) +++ debian/rules (working copy) @@ -53,6 +53,8 @@ dh_auto_build --sourcedirectory=wpa_supplicant \ --buildsystem=makefile \ --parallel + # build eapol_test + $(MAKE) -C wpa_supplicant/ eapol_test # build wpa_gui-qt4 dh_auto_build --sourcedirectory=wpa_supplicant/wpa_gui-qt4 \ --buildsystem=qmake \
signature.asc
Description: This is a digitally signed message part.