Merge branch 'bugfix/sta_add_config_for_wpa3_transition_disable_v4.3' into 'release/v4.3'

esp_wifi:Add wifi station config for enabling transition_disbale feature

See merge request espressif/esp-idf!21332
pull/10716/head
Jiang Jiang Jian 2023-01-17 19:56:03 +08:00
commit 56ee43ec5e
6 zmienionych plików z 21 dodań i 4 usunięć

Wyświetl plik

@ -281,7 +281,8 @@ typedef struct {
wifi_pmf_config_t pmf_cfg; /**< Configuration for Protected Management Frame. Will be advertized in RSN Capabilities in RSN IE. */
uint32_t rm_enabled:1; /**< Whether Radio Measurements are enabled for the connection */
uint32_t btm_enabled:1; /**< Whether BSS Transition Management is enabled for the connection */
uint32_t reserved:30; /**< Reserved for future feature set */
uint32_t transition_disable:1; /**< Whether to enable transition disable feature */
uint32_t reserved:29; /**< Reserved for future feature set */
wifi_sae_pwe_method_t sae_pwe_h2e; /**< Whether SAE hash to element is enabled */
uint8_t failure_retry_cnt; /**< Number of connection retries station will do before moving to next AP. scan_method should be set as WIFI_ALL_CHANNEL_SCAN to use this config. Note: Enabling this may cause connection time to increase incase best AP doesn't behave properly. */
} wifi_sta_config_t;

@ -1 +1 @@
Subproject commit c5c29fcdaa057a2f1f504e8c6eee64d3923767f1
Subproject commit 90d646774f5f1176564cc04cc1aeabeed407b82d

Wyświetl plik

@ -296,6 +296,10 @@ struct rsn_rdie {
#endif /* CONFIG_IEEE80211R */
/* WFA Transition Disable KDE (using OUI_WFA) */
/* Transition Disable Bitmap bits */
#define TRANSITION_DISABLE_WPA3_PERSONAL BIT(0)
struct wpa_ie_data {
int proto;
int pairwise_cipher;

Wyświetl plik

@ -61,6 +61,15 @@ void wpa_sm_free_eapol(u8 *buffer)
os_free(buffer);
}
void wpa_supplicant_transition_disable(void *sm, u8 bitmap)
{
wpa_printf(MSG_INFO, "TRANSITION_DISABLE %02x", bitmap);
if (bitmap & TRANSITION_DISABLE_WPA3_PERSONAL) {
esp_wifi_sta_disable_wpa2_authmode_internal();
}
}
void wpa_sm_deauthenticate(struct wpa_sm *sm, u8 reason_code)
{

Wyświetl plik

@ -28,6 +28,8 @@ void wpa_sm_disassociate(struct wpa_sm *sm, int reason_code);
int wpa_sm_get_beacon_ie(struct wpa_sm *sm);
void wpa_supplicant_transition_disable(void *sm, u8 bitmap);
void wpa_sm_free_eapol(u8 *buffer);
#endif /* WPAS_GLUE_H */

Wyświetl plik

@ -1355,8 +1355,9 @@ int ieee80211w_set_keys(struct wpa_sm *sm,
goto failed;
}
if (ie.transition_disable)
esp_wifi_sta_disable_wpa2_authmode_internal();
if (ie.transition_disable) {
wpa_supplicant_transition_disable(sm, ie.transition_disable[0]);
}
if (sm->key_install && sm->key_info & WPA_KEY_INFO_INSTALL && sm->use_ext_key_id) {
wpa_supplicant_install_ptk(sm, KEY_FLAG_RX);