From: Jouni Malinen Date: Tue, 21 Feb 2023 15:25:50 +0000 (+0200) Subject: FT: Store PTKSA entry for the correct BSSID in the FT protocol case X-Git-Tag: hostap_2_11~1282 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=91ad7a3098ef474f1e33ac7495309045bd0f32c1;p=thirdparty%2Fhostap.git FT: Store PTKSA entry for the correct BSSID in the FT protocol case sm->bssid has not yet been updated here, so use the provided bssid instead. This avoids replacing the PTKSA entry for the previous AP when a new PTKSA is being stored while using the FT protocol. Fixes: d70060f9665a ("WPA: Add PTKSA cache to wpa_supplicant for PASN") Signed-off-by: Jouni Malinen --- diff --git a/src/rsn_supp/wpa_ft.c b/src/rsn_supp/wpa_ft.c index 411596ad1..497d91e6d 100644 --- a/src/rsn_supp/wpa_ft.c +++ b/src/rsn_supp/wpa_ft.c @@ -511,7 +511,7 @@ static int wpa_ft_install_ptk(struct wpa_sm *sm, const u8 *bssid) } sm->tk_set = true; - wpa_sm_store_ptk(sm, sm->bssid, sm->pairwise_cipher, + wpa_sm_store_ptk(sm, bssid, sm->pairwise_cipher, sm->dot11RSNAConfigPMKLifetime, &sm->ptk); return 0; }