Commit Graph

320 Commits

Author SHA1 Message Date
tarun.kumar
e7a71f84b1 fix(esp_wifi): Modifying os_time_t datatype for platform and compiler independence 2025-04-24 20:00:08 +05:30
Jiang Jiang Jian
d91940e134 Merge branch 'bugfix/sae_send_confirm_v5.1' into 'release/v5.1'
fix(esp_wifi): Fix send_confirm according to specification provided by IEEE 802.11 (v5.1)

See merge request espressif/esp-idf!38437
2025-04-17 10:32:17 +08:00
Shreyas Sheth
e425609d74 fix(esp_wifi): Fix send_confirm according to specification provided by IEEE 802.11 2025-04-16 11:56:50 +05:30
Kapil Gupta
3748cc9da0 fix(esp_wifi): Code cleanup for PR#15550 PR#15551
Closes https://github.com/espressif/esp-idf/pull/15550
Closes https://github.com/espressif/esp-idf/pull/15551
2025-04-15 14:05:07 +08:00
Michael Stoll
e257f68a1d feat(esp_wifi): Implement esp_eap_client_set_domain_match 2025-04-15 14:05:07 +08:00
Aditi
c806d3e765 fix(wpa_supplicant): Add two separate flags for RRM and WNM
Added two separate flags CONFIG_RRM(80211k) and CONFIG_WNM(80211v)
    flags under IEEE80211KV support flag.
2025-04-07 16:03:47 +05:30
Nachiket Kukade
7c21e36a42 fix(wpa_supplicant): Fix some coverity issues in wpa_supplicant
1. Fix leak in SoftAP while sending SAE Confirm
2. Move NULL check before pointer is getting used
3. Remove some dead code
2025-04-07 16:03:47 +05:30
Shreyas Sheth
0cd6a2a8ee fix(wifi): Resolve comments for softap fixes 2025-04-07 16:03:41 +05:30
Shreyas Sheth
2474bab024 fix(wifi): Resolve comments on feature/softap_fixes_for_ceritification 2025-04-07 16:03:41 +05:30
Shreyas Sheth
f826a0cdc6 fix(wifi): Make sure auth is sent after sae process 2025-04-07 16:03:41 +05:30
Shreyas Sheth
979cd25e60 feat(wifi): Add support for transition_disable for softAP
Bugfix rsnxe len for assoc req
2025-04-07 16:03:41 +05:30
Sajia
762919054f fix(wifi): Fix crash when set config is called with changed password
Closes https://github.com/espressif/esp-idf/issues/15584
2025-04-04 00:14:26 +05:30
Sarvesh Bodakhe
0fd60e373e fix(wifi): Fix wrong PMKSA cache entry being used when wifi password is changed 2025-04-04 00:13:46 +05:30
Jiang Jiang Jian
eda82c2f2e Merge branch 'bugfix/analyzer_issues_supplicant_v5.1' into 'release/v5.1'
fix(esp_wifi): fix some analyzer issues (v5.1)

See merge request espressif/esp-idf!36833
2025-03-03 11:51:50 +08:00
Kapil Gupta
8652a5c552 fix(esp_wifi): fix some analyzer issues
Closes https://github.com/espressif/esp-idf/issues/15097
Closes https://github.com/espressif/esp-idf/issues/15098
Closes https://github.com/espressif/esp-idf/issues/15099
2025-03-02 17:06:12 +08:00
Shreyas Sheth
bbda0a9baa fix(wifi): Fixed memory leak occurring in SAE PK connection 2025-03-02 17:05:27 +08:00
Sarvesh Bodakhe
2665028530 feat(wpa_supplicant): Add WIFI_EVENT_AP_WRONG_PASSWORD in SoftAP
This event is triggered when external station tries connecting to softAP
with wrong password.

Currently supported softAP AUTH modes: WPA-PSK, WPA2-PSK and WPA3-PSK (SAE-auth)
2025-02-03 16:19:16 +05:30
Alexey Lapshin
7e7bd3f5a5 fix(wpa_supplicant): fix warnings found by GNU static analyzer 2025-01-24 11:32:19 +08:00
Jouni Malinen
84dc7782b7 SAE: Reject invalid Rejected Groups element in the parser
There is no need to depend on all uses (i.e., both hostapd and
wpa_supplicant) to verify that the length of the Rejected Groups field
in the Rejected Groups element is valid (i.e., a multiple of two octets)
since the common parser can reject the message when detecting this.

Signed-off-by: Jouni Malinen <j@w1.fi>
2024-12-03 14:05:21 +08:00
Jouni Malinen
2e25cef6b3 SAE: Check for invalid Rejected Groups element length explicitly
Instead of practically ignoring an odd octet at the end of the element,
check for such invalid case explicitly. This is needed to avoid a
potential group downgrade attack.

Signed-off-by: Jouni Malinen <j@w1.fi>
2024-12-03 14:05:21 +08:00
Jouni Malinen
3448ff697b SAE: Check that peer's rejected groups are not enabled in AP
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2024-12-03 14:05:21 +08:00
Shyamal Khachane
2eaee75296 fix(esp_wifi): Populate appropriate reason codes when softAP sends deauthentication
Populate appropriate reason for sending deauthentication when softAP receives
invalid RSN IE from association request
2024-11-27 00:34:50 +05:30
Kapil Gupta
beb46af390 fix(esp_wifi): Allow connection with WPA mode in WPS 2024-10-09 16:07:44 +05:30
Kapil Gupta
a6006f5a56 fix(esp_wifi): Added prints in btm roam for error condition 2024-10-07 10:42:32 +05:30
Kapil Gupta
4acdc6c830 fix(esp_wifi): Set PMK after SAE exchange 2024-09-27 12:27:32 +08:00
Sajia
0dbd2aa24c fix(esp_wifi): Refactor and update wpa_supplicant with upstream 2024-09-02 16:12:32 +05:30
Shyamal Khachane
39d284ba33 fix(esp_wifi): Handle PMKID mismatch or absence in OWE
Compute keys incase PMKID does not match or PMKID is absent in association response
2024-07-25 08:33:42 +05:30
muhaidong
1f74339756 fix(wifi): fix configure gcmp failure issue 2024-07-15 20:04:09 +08:00
Sarvesh Bodakhe
67de87c6ba fix(wpa_supplicant): Avoid delaying removal of wps enrollee by 10ms
This is no longer needed as eloop timers are now executed in wifi task context.
2024-07-12 12:03:30 +05:30
Sarvesh Bodakhe
23470b660e fix(wpa_supplicant): Handle case when WPS registrar misses WSC_DONE sent by station
When registrar somehow misses the WSC_DONE sent by station and station
goes for next connection after sending deauth, make sure that softAP
disables the registrar.
2024-07-12 12:03:06 +05:30
Sarvesh Bodakhe
de4010b95a feat(esp_wifi): Add support for WPA3 transition disable and more updates
1. Add support for SAE-PK and WPA3-Enterprise transition disable
2. Add support to handle OWE transition disable indication from AP
3. refactor: Backport common changes in scan/connect path from 90cc6158
   - 90cc6158 adds support for Network Introduction Protocol in DPP
4. Fix issue of supplicant using wrong parameters to configure bss
  - Ensure that wpa_supplicant's state machine registers the requirement for rsnxe
    before deciding to add rsnxe to a assoc request.

Co-authored-by: default avatarjgujarathi <jash.gujarathi@espressif.com>
2024-07-03 13:07:47 +05:30
Sarvesh Bodakhe
9d637316a9 fix(wifi): Add bugfix to avoid RSNXE and KDE mismatch during 4-way-handshake 2024-06-28 16:25:18 +05:30
Kapil Gupta
c5e1603e6d fix(wifi): Fix encryption/decryption issue for mgmt packets
* Fix issues related to mgmt packets encryption in GCMP
* Fix issue of wrong decryption of mgmt packets when PMF is enabled
* Fix softAP bug in handling of SAE Reauthentication
* Fix send mgmt err when eapol process
* Fix data len not correct in he actions
2024-06-28 16:24:54 +05:30
Nachiket Kukade
1614f9e3b5 fix(wpa_supplicant): Suppress RSN IE print to Verbose level 2024-05-29 11:09:57 +05:30
Shreyas Sheth
a64d8b12c8 fix(esp_wifi): Fix crash when assoc req comes before confirm is processed 2024-04-03 00:04:14 +05:30
Sarvesh Bodakhe
e1502fb99e fix(wifi): Avoid dereferencing a dangling function pointer in WPS supplicant
Avoid dereferencing a dangling function pointer in 'eap_server_sm_deinit()'.
This issue arises when hostap unregisteres EAP methods before it removes
the server state machine for station.
2024-03-18 12:44:53 +05:30
Kapil Gupta
6f9cc06b30 fix(wpa_supplicant): (PEAP client) Update Phase 2 auth requirements
The previous PEAP client behavior allowed the server to skip Phase 2
authentication with the expectation that the server was authenticated
during Phase 1 through TLS server certificate validation. Various PEAP
specifications are not exactly clear on what the behavior on this front
is supposed to be and as such, this ended up being more flexible than
the TTLS/FAST/TEAP cases. However, this is not really ideal when
unfortunately common misconfiguration of PEAP is used in deployed
devices where the server trust root (ca_cert) is not configured or the
user has an easy option for allowing this validation step to be skipped.

Change the default PEAP client behavior to be to require Phase 2
authentication to be successfully completed for cases where TLS session
resumption is not used and the client certificate has not been
configured. Those two exceptions are the main cases where a deployed
authentication server might skip Phase 2 and as such, where a more
strict default behavior could result in undesired interoperability
issues. Requiring Phase 2 authentication will end up disabling TLS
session resumption automatically to avoid interoperability issues.

Allow Phase 2 authentication behavior to be configured with a new phase1
configuration parameter option:
'phase2_auth' option can be used to control Phase 2 (i.e., within TLS
tunnel) behavior for PEAP:
 * 0 = do not require Phase 2 authentication
 * 1 = require Phase 2 authentication when client certificate
   (private_key/client_cert) is no used and TLS session resumption was
   not used (default)
 * 2 = require Phase 2 authentication in all cases
2024-03-15 13:22:10 +05:30
Sarvesh Bodakhe
344c5d1fce fix(wifi): fix bug in 'esp_wifi_deauthenticate_internal' and other improvements 2024-03-14 11:24:27 +05:30
Sarvesh Bodakhe
e5059dffec fix(wpa_supplicant): Add some bugfixes in wpa_supplicant
1) Add parameter to configure reason code of deauth frame
2) Add logs to indicate MIC failure 4-Way-Handshake
3) Process RSNXE capabilities only if AP advertises them
2024-03-14 11:23:05 +05:30
muhaidong
1881900781 fix(wifi): allow some special igtk keyindx to workaround faulty APs 2023-12-19 19:15:49 +08:00
Kapil Gupta
d9b36afbe6 fix(wpa_supplicant): Fix compilation issue in EAP disabled 2023-10-27 18:08:16 +05:30
aditi_lonkar
cc3b0d9f49 fix(wpa_supplicant): Fix few dpp bugs
1) Fix crash in dpp Listen without bootstrap
  2) Fix crash on receiving dpp auth_req from hostapd with dpp akm
2023-10-17 14:27:14 +05:30
Jiang Jiang Jian
face850973 Merge branch 'feature/rename_wpa2_ent_to_eap_client_v5.1' into 'release/v5.1'
WiFi: Rename WPA2 enterprise APIs to EAP Client. (v5.1)

See merge request espressif/esp-idf!26082
2023-09-26 13:30:52 +08:00
jgujarathi
3d056fd748 fix(esp_wifi): Fix issues with extended caps IE, scan and HT40 mode
-Merges the addition of extended caps IE for assoc req, probe resp
 and beacons in a single place. This ensures that there are no
 duplicate Extended Caps IE in the frame. Moves the capability
 indication for BTM and HT20/40 from supplicant to wifi libs.

-Fix issue with frequent disconections when scanning for only a single
 channel.

-Prints error message and returns ESP_ERR_NOT_SUPPORTED in case
 esp32c2 tries to set bandwidth to HT40.
2023-09-20 19:44:57 +08:00
Kapil Gupta
981086ba30 change(esp_wifi): Rename WiFi enterprise connection APIs 2023-09-20 17:06:59 +05:30
Jiang Jiang Jian
111779db5a Merge branch 'feature/configurable_wpa2_ent_v5.1' into 'release/v5.1'
Make enterprise support configurable to save binary size.(v5.1)

See merge request espressif/esp-idf!25558
2023-09-13 10:18:05 +08:00
Kapil Gupta
397206d050 change(wifi): Reduce BSS logging in wpa_supplicant 2023-09-07 10:19:02 +05:30
Jiang Jiang Jian
4299b9346b Merge branch 'bugfix/supplicant_osi_violation_v5.1' into 'release/v5.1'
Fix abstraction violation in wpa_supplicant (Backport v5.1)

See merge request espressif/esp-idf!25565
2023-08-28 10:30:37 +08:00
Nachiket Kukade
c15472b12e fix(supplicant): Fix abstraction violation in wpa_supplicant 2023-08-25 12:30:44 +05:30
aditi_lonkar
0624d5e58f esp_wifi: Make enterprise support configurable to save binary size. 2023-08-25 11:20:58 +05:30