diff --git a/src/rsn_supp/wpa.h b/src/rsn_supp/wpa.h index dbb493e4e..d4533a815 100644 --- a/src/rsn_supp/wpa.h +++ b/src/rsn_supp/wpa.h @@ -315,6 +315,7 @@ int wpa_ft_process_response(struct wpa_sm *sm, const u8 *ies, size_t ies_len, int ft_action, const u8 *target_ap, const u8 *ric_ies, size_t ric_ies_len); int wpa_ft_is_completed(struct wpa_sm *sm); +void wpa_reset_ft_completed(struct wpa_sm *sm); int wpa_ft_validate_reassoc_resp(struct wpa_sm *sm, const u8 *ies, size_t ies_len, const u8 *src_addr); int wpa_ft_start_over_ds(struct wpa_sm *sm, const u8 *target_ap, @@ -346,6 +347,10 @@ static inline int wpa_ft_is_completed(struct wpa_sm *sm) return 0; } +static inline void wpa_reset_ft_completed(struct wpa_sm *sm) +{ +} + static inline int wpa_ft_validate_reassoc_resp(struct wpa_sm *sm, const u8 *ies, size_t ies_len, const u8 *src_addr) diff --git a/src/rsn_supp/wpa_ft.c b/src/rsn_supp/wpa_ft.c index 4b08a624d..6b7fa91be 100644 --- a/src/rsn_supp/wpa_ft.c +++ b/src/rsn_supp/wpa_ft.c @@ -534,6 +534,13 @@ int wpa_ft_is_completed(struct wpa_sm *sm) } +void wpa_reset_ft_completed(struct wpa_sm *sm) +{ + if (sm != NULL) + sm->ft_completed = 0; +} + + static int wpa_ft_process_gtk_subelem(struct wpa_sm *sm, const u8 *gtk_elem, size_t gtk_elem_len) { diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c index 55a4d7c9b..887acb228 100644 --- a/wpa_supplicant/events.c +++ b/wpa_supplicant/events.c @@ -2466,6 +2466,7 @@ void wpa_supplicant_event(void *ctx, enum wpa_event_type event, data->deauth_info.ie, data->deauth_info.ie_len); } + wpa_reset_ft_completed(wpa_s->wpa); } #ifdef CONFIG_AP if (wpa_s->ap_iface && data && data->deauth_info.addr) {