]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Fix writing of BIGTK in FT protocol
authorJouni Malinen <quic_jouni@quicinc.com>
Thu, 10 Aug 2023 18:17:40 +0000 (21:17 +0300)
committerJouni Malinen <j@w1.fi>
Thu, 10 Aug 2023 18:17:40 +0000 (21:17 +0300)
A copy-paste issue in wpa_ft_bigtk_subelem() ended up encoding the IGTK
value instead of the BIGTK when providing the current BIGTK to the STA
during FT protocol. Fix this to use the correct key to avoid issues when
beacon protection is used with FT.

Fixes: 16889aff408e ("Add BIGTK KDE and subelement similarly to IGTK")
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
src/ap/wpa_auth_ft.c

index 8b91b822c6e250a43ac598791632284c4bb44847..8cd0cd23198e55fec543f021d18df626a163befb 100644 (file)
@@ -2398,7 +2398,7 @@ static u8 * wpa_ft_bigtk_subelem(struct wpa_state_machine *sm, size_t *len)
        wpa_auth_get_seqnum(sm->wpa_auth, NULL, gsm->GN_bigtk, pos);
        pos += 6;
        *pos++ = bigtk_len;
-       bigtk = gsm->IGTK[gsm->GN_bigtk - 6];
+       bigtk = gsm->BIGTK[gsm->GN_bigtk - 6];
        if (sm->wpa_key_mgmt == WPA_KEY_MGMT_OSEN) {
                /*
                 * Provide unique random BIGTK to each OSEN STA to prevent use