]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
FT: Fix GTK rekeying after FT protocol
authorJouni Malinen <j@w1.fi>
Sun, 1 Jun 2014 09:24:49 +0000 (12:24 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 1 Jun 2014 10:21:40 +0000 (13:21 +0300)
Move to PTKINITDONE state and mark PTK valid after successful completion
of FT protocol. This allows the AP/Authenticator to start GTK rekeying
when FT protocol is used. Previously, the station using FT protocol did
not get the new GTK which would break delivery of group addressed
frames.

Signed-off-by: Jouni Malinen <j@w1.fi>
src/ap/wpa_auth.c
src/ap/wpa_auth_ft.c

index d2126103d4d772b26908ae4870cafaa1d49cdce4..a9cd6f65e48d114484cac35ad7b3e25ce79fed05 100644 (file)
@@ -565,6 +565,8 @@ int wpa_auth_sta_associated(struct wpa_authenticator *wpa_auth,
                wpa_auth_logger(wpa_auth, sm->addr, LOGGER_DEBUG,
                                "FT authentication already completed - do not "
                                "start 4-way handshake");
+               /* Go to PTKINITDONE state to allow GTK rekeying */
+               sm->wpa_ptk_state = WPA_PTK_PTKINITDONE;
                return 0;
        }
 #endif /* CONFIG_IEEE80211R */
index 77015961bdb9ddf6e073f460d9b5aa457005e683..a80bbb7f4e2b6ce0803f5ff7f7020e31d580d303 100644 (file)
@@ -898,6 +898,7 @@ static int wpa_ft_process_auth_req(struct wpa_state_machine *sm,
        wpa_hexdump(MSG_DEBUG, "FT: PTKName", ptk_name, WPA_PMK_NAME_LEN);
 
        sm->pairwise = pairwise;
+       sm->PTK_valid = TRUE;
        wpa_ft_install_ptk(sm);
 
        buflen = 2 + sizeof(struct rsn_mdie) + 2 + sizeof(struct rsn_ftie) +