Commit Graph

45789 Commits

Author SHA1 Message Date
Jiang Jiang Jian
dc7c4c882c Merge branch 'fix/rtc_retain_mem_sb_fast_wakeup_ptr_v5.4' into 'release/v5.4'
fix(bootloader_support): fix RTC retain mem offset for secure boot fast wakeup (v5.4)

See merge request espressif/esp-idf!51269
2026-08-05 10:44:11 +08:00
Island
8c3500b917 Merge branch 'fix/ble_log_compression_add_local_header_file_v5.4' into 'release/v5.4'
feat(ble_log): mirror local compression headers (5.4)

See merge request espressif/esp-idf!50950
2026-08-05 10:06:54 +08:00
Jiang Jiang Jian
7ef63043e0 Merge branch 'bugfix/nan_vulnerabilities_v5.4' into 'release/v5.4'
fix(nan): Fix bug bounty reported and discovered vulnerabilities in NAN Rx (Backport v5.4)

See merge request espressif/esp-idf!51303
2026-08-04 20:37:26 +08:00
Euripedes Rocha
6dccb29a0f Merge branch 'fix/sec-1129-l2tap-close-rollback_v5.4' into 'release/v5.4'
fix(esp_netif): roll back l2tap_close on semaphore/task create failure (SEC-1129) (v5.4)

See merge request espressif/esp-idf!51400
2026-08-04 09:07:46 +02:00
Rahul Tank
6891e46417 Merge branch 'bugfix/add_nimble_cve_v5.4' into 'release/v5.4'
fix(nimble): Fixes for various NimBLE CVEs (v5.4)

See merge request espressif/esp-idf!51203
2026-08-04 12:15:02 +05:30
Wang Meng Yang
8945329c8b Merge branch 'fix/aireview_critical_v5.4' into 'release/v5.4'
fix: Fix some critical bugs in classic bt (v5.4)

See merge request espressif/esp-idf!51291
2026-08-04 14:16:22 +08:00
Wang Meng Yang
5340a84fc8 Merge branch 'fix/bluedroid_aireview_v5.4' into 'release/v5.4'
Fix/bluedroid aireview (v5.4)

See merge request espressif/esp-idf!51296
2026-08-04 14:12:25 +08:00
Luo Xu
e2114de7b0 feat(ble_log): mirror local compression headers
(cherry picked from commit ee732a4591)

Co-authored-by: luoxu <luoxu@espressif.com>
2026-08-04 11:53:15 +08:00
Rahul Tank
81d5a89bd9 fix(nimble): Fixes for various NimBLE CVEs 2026-08-03 23:47:07 +05:30
Euripedes Rocha Filho
24c3b92449 fix(esp_netif): Avoid socket to stay in closing state in l2tap closing 2026-08-03 16:14:32 +02:00
Island
ccd00fb116 Merge branch 'fix/ble_log_compression_issue_on_windows_v5.4' into 'release/v5.4'
fix(bt): fix BLE log compression build on Windows (5.4)

See merge request espressif/esp-idf!51244
2026-08-03 11:31:06 +08:00
Island
102d8c1141 Merge branch 'feat/update_mesh_lib_to_supported_get_lib_ver_v5.4' into 'release/v5.4'
Feat/update mesh lib to supported get lib ver (5.4)

See merge request espressif/esp-idf!51171
2026-08-03 11:30:27 +08:00
Martin Vychodil
102a347903 Merge branch 'bugfix/idfci-12815-12072-timeout_v5.4' into 'release/v5.4'
fix(storage): mark storage pytest apps flaky in CI (v5.4)

See merge request espressif/esp-idf!51338
2026-08-02 16:40:10 +08:00
sonika.rathi
bdeb413603 fix(storage): mark storage pytest apps flaky in CI 2026-07-31 08:55:18 +02:00
Akshat Agrawal
b08c5f7a22 fix(nan): Fix bug bounty reported and discovered vulnerabilities in NAN Rx 2026-07-31 11:38:48 +05:30
Island
ffc7e0dd66 Merge branch 'fix/fix_some_ble_sleep_issues_v5.4' into 'release/v5.4'
Fix/fix some ble sleep issues (5.4)

See merge request espressif/esp-idf!51317
2026-07-31 11:10:02 +08:00
harshal.patil
6618558e7b refactor(esp_system): deduplicate ROM fast wake RTC digest reservation
The digest length and the condition that reserves it at the end of RTC RAM were
duplicated in seven places. Hold the reservation in a hidden Kconfig value that
is zero when the feature does not apply, so every consumer subtracts it
unconditionally, and derive ESP_SECURE_BOOT_DIGEST_LEN from it.
2026-07-31 11:05:47 +08:00
hejiaxin
3552cb670a fix(bt_stack): Fix some critical bugs in classic_bt stack
related: obex, smp, pbap, sdp, rfcomm, stack_dm

- Deinit function doesn't delete connection when OBEX_DYNAMIC_MEMORY is on
- Union tGOEPC_DATA sometimes is free by osi_free in some cases when it contains mtu_id
- Add correct free and return solution after fail
- Fix symbol mistake in mod calculation
- Fix pointer-related UAF problems and memory free problems
- Fix buffer overflows and out-of-bounds access
- Fix infinite loops triggered by integer overflow wraparound
- Fix double free
- Change layer_specific usage to avoid heap overflow
- Add some NULL check for pointers
- Fix sdp_db free function
- Fix state table mismatch
2026-07-31 10:46:31 +08:00
Luo Xu
6d21650c9c fix(bt): Fixed build error on array-bounds in HFP AG
(cherry picked from commit bbd20cae01)

Co-authored-by: Wang Mengyang <wangmengyang@espressif.com>
2026-07-31 00:04:50 +08:00
Rahul Tank
4f16f3d939 Merge branch 'bugfix/fix_pawr_conn_event_v5.4' into 'release/v5.4'
fix(nimble):  Deliver PAwR peripheral CONNECT via sync callback (v5.4)

See merge request espressif/esp-idf!51255
2026-07-30 20:40:27 +05:30
Rahul Tank
b8fa51d316 fix(nimble): Deliver PAwR peripheral CONNECT via sync callback 2026-07-30 16:36:46 +05:30
Island
de4c7c205f Merge branch 'feat/add_bt_common_npl_v5.4' into 'release/v5.4'
feat(bt): Add host-agnostic BT OSAL and shared BLE profile task (5.4)

See merge request espressif/esp-idf!51232
2026-07-30 14:33:58 +08:00
Jiang Jiang Jian
58c0cf43fe Merge branch 'bugfix/fix_espnow_data_rate_error_v5.4' into 'release/v5.4'
fix(wifi): fixed espnow data rate overridden by stale rate control (v5.4)

See merge request espressif/esp-idf!51301
2026-07-30 11:53:03 +08:00
cjin
f40f40a86b feat(ble): added CONFIG_PM_SLP_IRAM_OPT to make sure cache error check 2026-07-30 10:17:47 +08:00
Island
750e5fc824 Merge branch 'change/ble_update_lib_20260717_v5.4' into 'release/v5.4'
change(ble): [AUTO_MR] 20260717 - Update ESP BLE Controller Lib (5.4)

See merge request espressif/esp-idf!50930
2026-07-30 10:08:00 +08:00
morris
8543b57cf1 Merge branch 'feat/sec_esp_drivers_v5.4' into 'release/v5.4'
fix(drivers): harden multiple peripheral drivers against local DoS and memory corruption (v5.4)

See merge request espressif/esp-idf!50559
2026-07-29 17:56:19 +08:00
zhangyanjiao
d6ad1e738d fix(wifi): fixed espnow data rate overridden by stale rate control 2026-07-29 17:37:09 +08:00
Jin Cheng
1ddbe558c4 fix(bt/bluedroid): fixed incorrect eSCO packet type validation under secure connection mode in BlueDroid 2026-07-29 17:30:30 +08:00
hejiaxin
829bdd89b5 fix(bt): Fix some bug in stm_sco.c
- Memory safety
- State machine & logic integrity
- Resource leaks
- Edge cases check
2026-07-29 17:30:30 +08:00
Jiang Jiang Jian
8b295c456a Merge branch 'bugfix/supplicant_crypto_code_correction_v5.4' into 'release/v5.4'
fix(wpa_supplicant): Correct some functions in crypto porting layer (v5.4)

See merge request espressif/esp-idf!50880
2026-07-29 15:29:34 +08:00
chenjianhua
9e83ae7a90 fix(provisioning): increase app partition size 2026-07-29 15:25:36 +08:00
chenjianhua
87af736067 feat(bt): Add host-agnostic BT OSAL and shared BLE profile task
- Add bt_osal: event queues, mutexes, semaphores, callouts, etc.
- Add the shared BLE profile task and event queue
- Bring both up and tear them down in the host init/deinit paths
- Add unit tests for the OSAL and the profile task
2026-07-29 15:25:36 +08:00
Jiang Jiang Jian
95d18299da Merge branch 'bugfix/clear_ifx_tx_queue_v5.4' into 'release/v5.4'
bugfix(wifi): Clear Sta TX queue to prevent key 2 send failure (Backport v5.4)

See merge request espressif/esp-idf!50897
2026-07-29 15:18:06 +08:00
akshat
9d07cbc3ed bugfix(wifi): Clear Sta TX queue to prevent key 2 send failure
Also, Ensure correct return values for key 2 and key 4.
2026-07-29 10:50:05 +05:30
morris
8e8be0cc7f fix(sdspi): reject oversized pre-read data before block receive
Guard start_command_read_blocks against cards that place TOKEN_BLOCK_START so early that extra_data_size exceeds the bytes expected on the current iteration. Without this check, the unsigned subtraction for will_receive underflows and propagates into memset, SPI transaction length, and memcpy counts against the fixed 516-byte block buffer.
2026-07-29 11:40:43 +08:00
morris
612eb0b97f fix(spi_slave): free DMA-private buffers when transaction queue is full
spi_slave_queue_trans calls spi_slave_setup_priv_trans to allocate
DMA buffers, then tries xQueueSend. If the queue is full the function
returns ESP_ERR_TIMEOUT without freeing those buffers, leaking up to
2 * max_transfer_sz per failed call. Call spi_slave_uninstall_priv_trans
before returning the timeout.
2026-07-29 11:40:43 +08:00
morris
b1d4725de1 fix(jpeg): release platform mutex on semaphore/pm-lock allocation failure
jpeg_acquire_codec_handle acquires s_jpeg_platform.mutex at entry
but two ESP_RETURN_ON_* macros (semaphore-create and PM-lock-create
failure) return without releasing it. Replace with ESP_GOTO_ON_*
that jumps to a cleanup label which frees partial resources, NULLs
the codec pointer, and releases the mutex.
2026-07-29 11:40:43 +08:00
morris
1428638fd6 fix(i2c): release platform mutex on intr/pm_lock delete failure
ESP_RETURN_ON_ERROR inside the s_i2c_platform.mutex critical section
returns without releasing the mutex, permanently blocking all I2C
bus operations. Replace with ESP_GOTO_ON_ERROR that jumps to a
cleanup label releasing the mutex before return.
2026-07-29 11:40:42 +08:00
morris
9f2a14562b fix(csi): move csi_fsm init before resource allocation to fix err-path leak
CSI_FSM_INIT is 1, but the controller struct is zero-allocated.
Any failure before the former csi_fsm assignment (near the end of
esp_cam_new_csi_ctlr) jumped to err: which called s_del_csi_ctlr.
That function bailed out immediately because csi_fsm == 0, leaking
the claimed slot, queue, bridge, DMA channel, PM lock, and backup
buffer. Move csi_fsm = CSI_FSM_INIT right after a successful claim
so the err: path properly tears down all allocated resources.
2026-07-29 11:34:57 +08:00
morris
b48a5356be fix(adc): add missing input validation for channel and ret_handle
- adc_cali_curve_fitting: validate config->chan in check_valid() to
  prevent OOB access into s_adc_cali_chan_compens compensation table
- adc_filter: make s_adc_filter_free idempotent on !UNIT_BINDED SoCs
  to prevent double-free on repeated adc_del_continuous_iir_filter
- adc_cali_line_fitting(esp32): fix config && config typo to
  config && ret_handle, preventing NULL-pointer dereference
2026-07-29 11:34:57 +08:00
Jiang Jiang Jian
095f3c2e83 Merge branch 'bugfix/fix_some_coex_bugs_260723_v5.4' into 'release/v5.4'
Bugfix/fix some coex bugs 260723 v5.4(Backport v5.4)

See merge request espressif/esp-idf!51103
2026-07-29 10:19:09 +08:00
Jiang Jiang Jian
a2695ee1f5 Merge branch 'fix/fix_iram_sleep_process_access_cache_v5.4' into 'release/v5.4'
fix(esp_hw_support): fix get_act_hp/lp_dbias accessed ext mem (v5.4)

See merge request espressif/esp-idf!51213
2026-07-29 10:18:57 +08:00
Jin Chen
708d93fbf5 change(ble): [AUTO_MR] Update lib_esp32c6 to 18aafc6f
(cherry picked from commit 624845829a)

Co-authored-by: cjin <jinchen@espressif.com>
2026-07-29 08:37:20 +08:00
Jin Chen
4ff112dace change(ble): [AUTO_MR] Update lib_esp32h2 to 18aafc6f
(cherry picked from commit d7b7876c3c)

Co-authored-by: cjin <jinchen@espressif.com>
2026-07-29 08:37:20 +08:00
wuzhenghui
d7cdfc1abf fix(bootloader_support): fix RTC retain mem offset for secure boot fast wakeup
Pointer arithmetic on rtc_retain_mem_t* subtracted ESP_SECURE_BOOT_DIGEST_LEN
in struct units instead of bytes. Cast through uintptr_t so retain mem stays
below the ROM verified-image digest region on deep-sleep wake.

Partial backport of !51265 (bootloader_common_loader.c only).
2026-07-28 21:50:45 +08:00
morris
7db201bca4 Merge branch 'fix/uhci_rx_size_check_v5.4' into 'release/v5.4'
fix(uhci): rx fsm race condition and buffer size check (v5.4)

See merge request espressif/esp-idf!51233
2026-07-28 18:23:09 +08:00
Hu Rui
3a46556120 fix(uhci): rx fsm race condition and buffer size check
Closes https://github.com/espressif/esp-idf/issues/18819
Closes https://github.com/espressif/esp-idf/issues/18820
2026-07-28 14:11:25 +08:00
Luo Xu
c974c55606 fix(bt): fix BLE log compression build on Windows
The BLE log compression feature (CONFIG_BT_LOG_CRITICAL_ONLY ->
BLE_COMPRESSED_LOG_ENABLE) failed to build on Windows while working
correctly on Linux, due to two shell/platform-specific issues in the
compression script.

1. Module/source argument quoting. CMakeLists.txt passes the
   semicolon-separated module and source lists wrapped in single quotes
   ("'${MODULES}'") to protect ';' from POSIX shells, which strip them.
   cmd.exe does not treat single quotes as quoting characters, so on
   Windows the quotes reached the script literally and
   args.module.split(';') produced "'BLE_MESH" / "BLE_HOST'" instead of
   the clean names. These never matched the YAML module keys, every
   module was skipped ("Skipping module ... - config not found"), the
   compressed sources were never generated, and the build failed. Strip
   surrounding quote characters before splitting; this is a no-op on
   Linux/macOS where the shell already removed them.

2. CRLF line endings. With core.autocrlf=true the IDF sources are
   checked out as CRLF on Windows. The generated *_log_index.h macros
   use backslash-newline line-continuation; a backslash followed by
   '\r\n' is not a valid continuation in C, producing floods of syntax
   errors when the header is compiled. Write generated headers with
   newline='' to force LF, and normalize source content to LF right
   after reading so '\r' embedded inside multi-line argument expressions
   is also handled. Byte offsets stay consistent because both tree-sitter
   parsing and tag replacement operate on the normalized content.

Verified by full clean builds of examples/bluetooth/esp_ble_mesh/
vendor_models/vendor_client (esp32c6, bluedroid + mesh) from both
cmd.exe and PowerShell; both produce an identical vendor_client.bin.


(cherry picked from commit aa9b565a6d)

Co-authored-by: luoxu <luoxu@espressif.com>
2026-07-28 13:43:35 +08:00
luoxu
269588b7cb feat(ble_mesh): update lib to 79e3fee04e 2026-07-28 12:11:38 +08:00
Euripedes Rocha
0cbe0d8192 Merge branch 'fix/w5500_rx_buffer_corruption_recovery_v5.4' into 'release/v5.4'
fix(esp_eth): recover W5500 RX path on corrupted frame length (v5.4)

See merge request espressif/esp-idf!50648
2026-07-27 14:19:19 +02:00