diff options
author | David Smith <david.daniel.smith@gmail.com> | 2009-11-11 15:46:15 (GMT) |
---|---|---|
committer | Jouni Malinen <j@w1.fi> | 2010-01-09 17:49:52 (GMT) |
commit | 5530eaef0c7a44e8986f4f24638bb64bc53e0bfd (patch) | |
tree | 51d6d8b4db5a227f0f5e9d51b1dba2df90de344e | |
parent | ab8ed0c8371544ccefebf8dfcc6923c5cf76607c (diff) | |
download | hostap-06-5530eaef0c7a44e8986f4f24638bb64bc53e0bfd.zip hostap-06-5530eaef0c7a44e8986f4f24638bb64bc53e0bfd.tar.gz hostap-06-5530eaef0c7a44e8986f4f24638bb64bc53e0bfd.tar.bz2 |
Reset EAPOL pointer when handling DBus smartcard parameters
Smartcard parameter update via DBus ended up re-initializing the EAPOL
state machine without updating the pointer inside WPA state machine.
This can trigger a segfault when EAP layer attempts to use the old
reference. Fix this by re-initializing the pointer inside WPA state
machine.
(cherry picked from commit d7199342f0633b5ab147dca5b885530fe32ceaeb)
Conflicts:
wpa_supplicant/ctrl_iface_dbus_handlers.c
-rw-r--r-- | wpa_supplicant/ctrl_iface_dbus_handlers.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/wpa_supplicant/ctrl_iface_dbus_handlers.c b/wpa_supplicant/ctrl_iface_dbus_handlers.c index 1c3dcd6..d3250d3 100644 --- a/wpa_supplicant/ctrl_iface_dbus_handlers.c +++ b/wpa_supplicant/ctrl_iface_dbus_handlers.c @@ -24,6 +24,7 @@ #include "ieee802_11_defs.h" #include "wpas_glue.h" #include "eapol_supp/eapol_supp_sm.h" +#include "wpa.h" extern int wpa_debug_level; extern int wpa_debug_show_keys; @@ -1294,8 +1295,11 @@ DBusMessage * wpas_dbus_iface_set_smartcard_modules( wpa_s->conf->pkcs11_module_path = pkcs11_module_path; #endif /* EAP_TLS_OPENSSL */ + wpa_sm_set_eapol(wpa_s->wpa, NULL); eapol_sm_deinit(wpa_s->eapol); + wpa_s->eapol = NULL; wpa_supplicant_init_eapol(wpa_s); + wpa_sm_set_eapol(wpa_s->wpa, wpa_s->eapol); return wpas_dbus_new_success_reply(message); |