kopia lustrzana https://github.com/espressif/esp-idf
Merge branch 'bugfix/add_unregister_wpa3_cb_v4.4' into 'release/v4.4'
wpa_supplicant : Add support for unregistering wifi wpa3 callbacks. See merge request espressif/esp-idf!22556pull/11147/head
commit
f3fc6f7435
|
@ -260,4 +260,12 @@ void esp_wifi_register_wpa3_cb(struct wpa_funcs *wpa_cb)
|
|||
wpa_cb->wpa3_parse_sae_msg = wpa3_parse_sae_msg;
|
||||
}
|
||||
|
||||
void esp_wifi_unregister_wpa3_cb(void)
|
||||
{
|
||||
extern struct wpa_funcs *wpa_cb;
|
||||
|
||||
wpa_cb->wpa3_build_sae_msg = NULL;
|
||||
wpa_cb->wpa3_parse_sae_msg = NULL;
|
||||
|
||||
}
|
||||
#endif /* CONFIG_WPA3_SAE */
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include "esp_wpa2.h"
|
||||
#include "esp_common_i.h"
|
||||
|
||||
struct wpa_funcs *wpa_cb;
|
||||
void wpa_install_key(enum wpa_alg alg, u8 *addr, int key_idx, int set_tx,
|
||||
u8 *seq, size_t seq_len, u8 *key, size_t key_len, enum key_flag key_flag)
|
||||
{
|
||||
|
@ -229,7 +230,6 @@ static void wpa_sta_disconnected_cb(uint8_t reason_code)
|
|||
int esp_supplicant_init(void)
|
||||
{
|
||||
int ret = ESP_OK;
|
||||
struct wpa_funcs *wpa_cb;
|
||||
|
||||
wpa_cb = (struct wpa_funcs *)os_zalloc(sizeof(struct wpa_funcs));
|
||||
if (!wpa_cb) {
|
||||
|
|
|
@ -618,6 +618,7 @@ void eap_peer_config_deinit(struct eap_sm *sm)
|
|||
os_free(sm->config.new_password);
|
||||
os_free(sm->config.eap_methods);
|
||||
os_bzero(&sm->config, sizeof(struct eap_peer_config));
|
||||
config_methods = NULL;
|
||||
}
|
||||
|
||||
int eap_peer_blob_init(struct eap_sm *sm)
|
||||
|
|
|
@ -2421,7 +2421,19 @@ int wpa_set_bss(char *macddr, char * bssid, u8 pairwise_cipher, u8 group_cipher,
|
|||
extern bool g_wpa_suiteb_certification;
|
||||
if (g_wpa_suiteb_certification) {
|
||||
if (mgmt_cipher != WIFI_CIPHER_TYPE_AES_GMAC256) {
|
||||
wpa_printf(MSG_ERROR, "suite-b 192bit certification, only GMAC256 is supported");
|
||||
wpa_printf(MSG_ERROR, "suite-b 192bit certification, only GMAC256 is supported for management cipher");
|
||||
return -1;
|
||||
}
|
||||
if (sm->group_cipher != WPA_CIPHER_GCMP_256) {
|
||||
wpa_printf(MSG_ERROR, "suite-b 192bit certification, only group GCMP256 is supported for group data cipher.");
|
||||
return -1;
|
||||
}
|
||||
if (sm->pairwise_cipher != WPA_CIPHER_GCMP_256) {
|
||||
wpa_printf(MSG_ERROR,"suite-b 192bit certification, only group GCMP256 is supported for pairwise cipher");
|
||||
return -1;
|
||||
}
|
||||
if (sm->key_mgmt != WPA_KEY_MGMT_IEEE8021X_SUITE_B_192) {
|
||||
wpa_printf(MSG_ERROR, "suite-b 192bit certification, 192bit akm supported");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue