path: root/wpa_supplicant/notify.c
diff options
authorAhmed ElArabawy <arabawy@google.com>2018-03-15 16:00:10 (GMT)
committerJouni Malinen <j@w1.fi>2018-03-31 08:57:33 (GMT)
commit45f7574d31b543ef4f65551d095be2b42a32ac77 (patch)
tree2577288e516d0902ee428794f785df37a4145970 /wpa_supplicant/notify.c
parentc9aba19bd34af3f04517ca6bf37891d0ecb4d59b (diff)
Propagate the EAP method error code
In the current implementation, upon an EAP method failure, followed by an EAP failure, the EAP Status is propagated up in wpa_supplicant with a general failure parameter string "failure". This parameter is used for a notification on the dbus. This commit reports the EAP method failure error code in a separate callback. The solution in this commit is generic to all EAP methods, and can be used by any method that need to pass its error code. However, this commit only implements the reporting for EAP-SIM and EAP-AKA methods where the Notification Code (in AT_NOTIFICATION) is used as the method specific error code value. Signed-off-by: Ahmed ElArabawy <arabawy@google.com>
Diffstat (limited to 'wpa_supplicant/notify.c')
1 files changed, 6 insertions, 0 deletions
diff --git a/wpa_supplicant/notify.c b/wpa_supplicant/notify.c
index 3e67a77..83df04f 100644
--- a/wpa_supplicant/notify.c
+++ b/wpa_supplicant/notify.c
@@ -816,6 +816,12 @@ void wpas_notify_eap_status(struct wpa_supplicant *wpa_s, const char *status,
+void wpas_notify_eap_error(struct wpa_supplicant *wpa_s, int error_code)
+ wpa_msg(wpa_s, MSG_ERROR, WPA_EVENT_EAP_ERROR_CODE "%d", error_code);
void wpas_notify_network_bssid_set_changed(struct wpa_supplicant *wpa_s,
struct wpa_ssid *ssid)