diff --git a/components/esp_wifi/lib b/components/esp_wifi/lib index ef66afa203..e6c344109c 160000 --- a/components/esp_wifi/lib +++ b/components/esp_wifi/lib @@ -1 +1 @@ -Subproject commit ef66afa2032019091430c00f41d13ef77574170d +Subproject commit e6c344109c40d67bc783b09223756b1f42919d02 diff --git a/components/wpa_supplicant/esp_supplicant/src/esp_hostap.c b/components/wpa_supplicant/esp_supplicant/src/esp_hostap.c index 878695691a..57559a3f53 100644 --- a/components/wpa_supplicant/esp_supplicant/src/esp_hostap.c +++ b/components/wpa_supplicant/esp_supplicant/src/esp_hostap.c @@ -130,6 +130,21 @@ void *hostap_init(void) wpa_printf(MSG_DEBUG, "%s : pmf optional", __func__); } + if (auth_conf->ieee80211w != NO_MGMT_FRAME_PROTECTION) { + switch (pairwise_cipher) { + case WIFI_CIPHER_TYPE_CCMP: + auth_conf->group_mgmt_cipher = WPA_CIPHER_AES_128_CMAC; + break; + case WIFI_CIPHER_TYPE_GCMP: + auth_conf->group_mgmt_cipher = WPA_CIPHER_BIP_GMAC_128; + break; + case WIFI_CIPHER_TYPE_GCMP256: + auth_conf->group_mgmt_cipher = WPA_CIPHER_BIP_GMAC_256; + break; + default: + auth_conf->group_mgmt_cipher = WPA_CIPHER_AES_128_CMAC; + } + } if (authmode == WIFI_AUTH_WPA2_WPA3_PSK) { auth_conf->wpa_key_mgmt |= WPA_KEY_MGMT_SAE; }