Skip to content

Commit 02e19c4

Browse files
committed
Merge branch 'bugfix/wrong_ic_parameters_in_connect_v5.3' into 'release/v5.3'
fix(wifi): Fix issue of supplicant using wrong parameters to configure bss (Backport v5.3) See merge request espressif/esp-idf!32068
2 parents 28c124d + 8a0a093 commit 02e19c4

File tree

4 files changed

+6
-3
lines changed

4 files changed

+6
-3
lines changed

components/wpa_supplicant/esp_supplicant/src/esp_wifi_driver.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,6 @@ struct wpa_funcs {
142142
void (*wpa_config_done)(void);
143143
uint8_t *(*owe_build_dhie)(uint16_t group);
144144
int (*owe_process_assoc_resp)(const u8 *rsn_ie, size_t rsn_len, const uint8_t *dh_ie, size_t dh_len);
145-
int (*wpa_sta_set_ap_rsnxe)(const u8 *rsnxe, size_t rsnxe_ie_len);
146145
};
147146

148147
struct wpa2_funcs {

components/wpa_supplicant/esp_supplicant/src/esp_wpa_main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,6 @@ int esp_supplicant_init(void)
469469
wpa_cb->wpa_config_bss = NULL;//wpa_config_bss;
470470
wpa_cb->wpa_michael_mic_failure = wpa_michael_mic_failure;
471471
wpa_cb->wpa_config_done = wpa_config_done;
472-
wpa_cb->wpa_sta_set_ap_rsnxe = wpa_sm_set_ap_rsnxe;
473472

474473
esp_wifi_register_wpa3_ap_cb(wpa_cb);
475474
esp_wifi_register_wpa3_cb(wpa_cb);

components/wpa_supplicant/src/rsn_supp/wpa.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2434,6 +2434,11 @@ int wpa_set_bss(char *macddr, char * bssid, u8 pairwise_cipher, u8 group_cipher,
24342434
if (res < 0)
24352435
return -1;
24362436
sm->assoc_wpa_ie_len = res;
2437+
2438+
const u8 *rsnxe;
2439+
rsnxe = esp_wifi_sta_get_rsnxe((u8*)bssid);
2440+
wpa_sm_set_ap_rsnxe(rsnxe, rsnxe ? (rsnxe[1] + 2) : 0);
2441+
24372442
res = wpa_gen_rsnxe(sm, assoc_rsnxe, assoc_rsnxe_len);
24382443
if (res < 0)
24392444
return -1;

0 commit comments

Comments
 (0)