Skip to content

Commit 19162d8

Browse files
committed
Merge branch 'bugfix/supplicant_memory_overflow' into 'master'
fix(esp_wifi): Prevent memory overflow in WPS See merge request espressif/esp-idf!33712
2 parents 03b73cf + d2e0eb7 commit 19162d8

File tree

1 file changed

+1
-1
lines changed
  • components/wpa_supplicant/esp_supplicant/src

1 file changed

+1
-1
lines changed

components/wpa_supplicant/esp_supplicant/src/esp_wps.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1394,7 +1394,7 @@ void wifi_station_wps_eapol_start_handle(void *data, void *user_ctx)
13941394
static int save_credentials_cb(void *ctx, const struct wps_credential *cred)
13951395
{
13961396
struct wps_credential *creds;
1397-
if (!gWpsSm || !cred || gWpsSm->ap_cred_cnt > MAX_CRED_COUNT) {
1397+
if (!gWpsSm || !cred || gWpsSm->ap_cred_cnt >= MAX_CRED_COUNT) {
13981398
return ESP_FAIL;
13991399
}
14001400

0 commit comments

Comments
 (0)