mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
Correct SSID copy length during WPS scan
This commit is contained in:
parent
c135695a18
commit
4a5f26d7fc
@ -1104,7 +1104,7 @@ static struct wpabuf * eap_peap_process(struct eap_sm *sm, void *priv,
|
||||
}
|
||||
|
||||
if (tls_connection_established(sm->ssl_ctx, data->ssl.conn)) {
|
||||
char label[24];
|
||||
char label[24] = {0};
|
||||
wpa_printf(MSG_DEBUG, "EAP-PEAP: TLS done, proceed to Phase 2");
|
||||
os_free(data->key_data);
|
||||
/* draft-josefsson-ppext-eap-tls-eap-05.txt
|
||||
|
@ -612,7 +612,7 @@ wps_parse_scan_result(struct wps_scan_ie *scan)
|
||||
}
|
||||
esp_wifi_enable_sta_privacy_internal();
|
||||
os_memset(sm->config.ssid, 0, sizeof(sm->config.ssid));
|
||||
strncpy((char *)sm->config.ssid, (char *)&scan->ssid[2], (int)scan->ssid[1]);
|
||||
os_memcpy(sm->config.ssid, (char *)&scan->ssid[2], (int)scan->ssid[1]);
|
||||
if (scan->bssid && memcmp(sm->config.bssid, scan->bssid, ETH_ALEN) != 0) {
|
||||
wpa_printf(MSG_INFO, "sm BSSid: "MACSTR " scan BSSID " MACSTR "\n",
|
||||
MAC2STR(sm->config.bssid), MAC2STR(scan->bssid));
|
||||
|
Loading…
Reference in New Issue
Block a user