[PATCH] FT: remove ft_ies when supplicant marked as disassoc
Jouni Malinen
j
Tue Jul 5 11:19:26 PDT 2011
On Tue, Jun 28, 2011 at 01:01:28AM +0300, Hong Wu wrote:
> Previous ft_ies should be removed before supplicant starts a new FT
> initial association.
> diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c
> @@ -127,6 +127,13 @@ void wpa_supplicant_mark_disassoc(struct
> +#ifdef CONFIG_IEEE80211R
> + if (wpa_s->sme.ft_ies) {
> + os_free(wpa_s->sme.ft_ies);
> + wpa_s->sme.ft_ies = NULL;
> + wpa_s->sme.ft_ies_len = 0;
> + wpa_s->sme.ft_used = 0;
> +#endif /* CONFIG_IEEE80211R */
The need for this was a bit difficult to understand based on the commit
message, but I think the real issue here was in wpa_s->sme.ft_used not
getting cleared and that resulting in new ft_ies buffer being used in
sme_authenticate().
In addition, this needs some more protection to avoid breaking builds
that do not define CONFIG_SME (and well, the missing '}' is needed,
too. I applied this with the build issues fixed and by using the
existing sme_update_ft_ies() function to clear the state to avoid
duplicated code for this.
--
Jouni Malinen PGP id EFC895FA
More information about the Hostap
mailing list