From ded56f2fafb00090118f82a135aa63b393cc66cf Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Fri, 16 Aug 2019 13:23:06 +0300 Subject: [PATCH] FT: Fix MFPR flag in RSNE during FT protocol Commit e820cf952f29 ("MFP: Add MFPR flag into station RSN IE if 802.11w is mandatory") added indication of MFPR flag in non-FT cases, but forgot to do so for the FT protocol cases where a different function is used to build the RSNE. Do the same change now for that FT specific case to get consistent behavior on indicating PMF configuration state with MFPR. Signed-off-by: Jouni Malinen --- src/rsn_supp/wpa_ft.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/rsn_supp/wpa_ft.c b/src/rsn_supp/wpa_ft.c index 46ffdca67..7e8b523e4 100644 --- a/src/rsn_supp/wpa_ft.c +++ b/src/rsn_supp/wpa_ft.c @@ -247,11 +247,10 @@ static u8 * wpa_ft_gen_req_ies(struct wpa_sm *sm, size_t *len, /* RSN Capabilities */ capab = 0; #ifdef CONFIG_IEEE80211W - if (sm->mgmt_group_cipher == WPA_CIPHER_AES_128_CMAC || - sm->mgmt_group_cipher == WPA_CIPHER_BIP_GMAC_128 || - sm->mgmt_group_cipher == WPA_CIPHER_BIP_GMAC_256 || - sm->mgmt_group_cipher == WPA_CIPHER_BIP_CMAC_256) + if (sm->mfp) capab |= WPA_CAPABILITY_MFPC; + if (sm->mfp == 2) + capab |= WPA_CAPABILITY_MFPR; #endif /* CONFIG_IEEE80211W */ if (sm->ocv) capab |= WPA_CAPABILITY_OCVC;