Commit Graph

1313 Commits

Author SHA1 Message Date
harshal.patil
a7b29bfda9 change(security): disable Key Manager support on ESP32-C5/P4/S31
The Key Manager hardware peripheral in its current form needs further
design changes before it can be offered as a production feature.
Until a revised peripheral design is available, withdraw ESP-IDF
support for it on all Key Manager capable targets.
2026-07-22 19:58:23 +05:30
Nilesh Kale
c3fafbb527 Merge branch 'fix/esp32p4_secure_boot_sig_block' into 'master'
fix(esp32p4): secure boot (ECDSA-P384) and flash encryption eFuse fixes

See merge request espressif/esp-idf!49827
2026-07-17 13:26:34 +08:00
Jiang Jiang Jian
f84166fcdb Merge branch 'bugfix/fix_coex_status_get_issue' into 'master'
fix(coex): fix coex status get issue

Closes WIFIBUG-2018

See merge request espressif/esp-idf!50739
2026-07-17 10:43:57 +08:00
Renz Christian Bagaporo
faca8f56a3 Merge branch 'feat/cmakev2_ulp_full_subproject' into 'master'
feat(ulp): initial support for building ULP projects as full subprojects under CMake v2

See merge request espressif/esp-idf!50134
2026-07-16 21:00:32 +08:00
muhaidong
7e5d9825da fix(coex): fix coex status get issue 2026-07-16 20:58:09 +08:00
nilesh.kale
f5b861783d fix(esp_rom): correct ESP32-P4 secure boot signature block layout 2026-07-16 14:29:33 +05:30
Alexey Lapshin
c4463d7c04 feat(tools): tools: update esp-rom-elf to version 20260528
Closes https://github.com/espressif/esp-idf/issues/18755
2026-07-15 15:58:30 +07:00
Renz Bagaporo
7d75f85221 feat(ulp): build ULP full subprojects as CMake v2 children 2026-07-15 09:14:35 +09:00
morris
18f50fefa9 Merge branch 'feat/esp_macro_align_up_down' into 'master'
refactor(esp_common): centralize ALIGN_UP/ALIGN_DOWN into esp_macros.h

See merge request espressif/esp-idf!50335
2026-07-06 19:09:14 +08:00
morris
651d6a283f refactor(esp_common): centralize ALIGN_UP/ALIGN_DOWN into esp_macros.h
Remove ~50 duplicate local definitions of ALIGN_UP/ALIGN_DOWN/ALIGN_UP_BY/
ALIGN_DOWN_BY across the codebase and replace them with canonical
ESP_ALIGN_UP/ESP_ALIGN_DOWN from esp_macros.h.
2026-07-06 13:36:06 +08:00
nilesh.kale
fe18ed97dd feat: added call to aquire clock source for H4 and H21 AES crypto 2026-07-06 10:12:35 +05:30
morris
aa4532395a fix(esp_crc): clarify CRC helper usage documentation
Document the implicit bitwise inversion behavior in the CRC ROM wrappers
and add regression tests covering continuous-buffer examples.

Closes https://github.com/espressif/esp-idf/issues/18715
2026-06-30 15:37:06 +08:00
yinqingzhao
7aa7a9da9c fix(wifi): comment out functions from ld files 2026-06-29 16:18:38 +08:00
Michael (XIAO Xufeng)
c1b218b640 Merge branch 'fix/mmap_cache_flash_wr' into 'master'
fix(mmap): fixed mmap read data wrong when flash being erased/written and cache not disabled

Closes IDFGH-14084

See merge request espressif/esp-idf!29804
2026-06-29 11:44:10 +08:00
yinqingzhao
657d43c1e6 fix(wifi): comment out pm_process_tim from ld files for esp32c61 2026-06-17 09:55:01 +08:00
Xiao Xufeng
789ce684c9 fix(mmap): fixed some API read wrong data via mmap when flash being erased/written while XIP on PSRAM
Before:

The cache won't be disabled when XIP on psram. But during flash
erasing/programming, read data will be courrupt.

When XIP in psram is enabled, the image is not mapped to the cache so
usually there will be no flash access. The only way to read from flash
is via the driver or use mmap. The driver has protection during erasing,
while th mmap region not.

Now:

Mmap APIs provide a flag to make mmap->unmap region mutually exclusive
to flash erase/programming when XIP from psram. SPI Flash write APIs
will benefit from this. When the flag is used, no concurrent access to
mapped region will happen while writing; otherwise the cache will be
disable to avoid data corruption.

Most ESP-IDF APIs calls mmap with this flag. As for users calling
mmap-like APIs directly, they can choose whether to enable this by a
flag.

Closes https://github.com/espressif/esp-idf/issues/14897
2026-06-16 01:00:43 +08:00
harshal.patil
f68bc1ba9f fix(secure_boot): range-check ECDSA r,s in bootloader before ROM verify 2026-06-12 14:38:47 +05:30
yinqingzhao
63b92cf17e fix(wifi): fix scheduling issue when tasks have the same priority as the Wi-Fi task 2026-06-10 11:48:26 +08:00
Harshal Patil
a5591852c5 Merge branch 'fix/remove_nonexistent_crypto_registers_c61' into 'master'
Remove non-existent crypto registers (ESP32-C61)

See merge request espressif/esp-idf!49241
2026-06-09 18:16:01 +05:30
Mahavir Jain
05c70c1fd4 Merge branch 'fix/ecdsa_ecc_hw_input_validation' into 'master'
Validate ECDSA signature range and harden ECC memory power-down

See merge request espressif/esp-idf!48958
2026-06-09 14:40:24 +05:30
harshal.patil
81ffe04323 fix(soc): Remove non-existent crypto registers (ESP32-C61) 2026-06-09 13:33:25 +05:30
harshal.patil
c5e03fd55c fix(esp_rom): Patch ets_ecdsa_verify() to include signature bounds check 2026-06-09 10:59:12 +05:30
Song Ruo Jing
545b31e6b9 feat(spi_flash): Add exclusive support for ESP32H4
Add 32bit addr support for esp32s31 as well
2026-06-08 17:56:09 +08:00
C.S.M
747c1c9555 Merge branch 'fix/s31_suspend' into 'master'
fix(spi_flash): Fix suspend issue on esp32s31, and add trs timing on other target

See merge request espressif/esp-idf!49228
2026-06-08 14:31:35 +08:00
C.S.M
2acd9b9a7c fix(spi_flash): Fix suspend issue on esp32s31, and add trs timing on other target 2026-06-08 11:15:13 +08:00
sibeibei
ec8b578924 fix(phy): fix wifi tx failed when sta wake from deepsleep 2026-06-04 21:01:44 +08:00
Jiang Jiang Jian
5fc361d5d0 Merge branch 'bugfix/fix_some_rom_func_ld_issue' into 'master'
fix(wifi): fix som rom func ld issue

See merge request espressif/esp-idf!49004
2026-06-01 11:12:04 +08:00
Mahavir Jain
d0fb1cdad8 Merge branch 'feat/enable_sb_and_fe_support_for_esp32s31' into 'master'
feat: enable Secure Boot, Flash Encryption and Key Manager support in ESP32S31

Closes IDF-14629, IDF-14628, IDF-14626, and IDF-14622

See merge request espressif/esp-idf!48136
2026-05-29 10:31:34 +05:30
muhaidong
c2611cd018 fix(wifi): fix som rom func ld issue 2026-05-28 15:49:20 +08:00
wanglei
b2a8695c15 fix(esp_rom): Cache_WriteBack_All patch should skip bootloader 2026-05-26 14:24:58 +08:00
nilesh.kale
fe257f699e feat: enable Secure Boot, Flash Encryption and Key Manager support for S31 2026-05-26 12:57:34 +08:00
Konstantin Kondrashov
7dab1d313e Merge branch 'feature/efuse_esp32h21' into 'master'
feat(efuse): Update efuse table for ESP32H21

Closes IDF-11556

See merge request espressif/esp-idf!48762
2026-05-22 09:39:18 +03:00
Jiang Jiang Jian
90ec41a9f7 Merge branch 'feat/support_rom_psa_mbedtls' into 'master'
feat(mbedtls): enable ESP32-C2(Rev2.0) ROM mbedTLS crypto for PSA

Closes IDF-15012

See merge request espressif/esp-idf!48211
2026-05-22 11:24:42 +08:00
Jiang Jiang Jian
fff1564266 Merge branch 'fix/for_cache_after_p4_wb_loss_issue' into 'master'
fix(esp_rom): avoid critical issue in writeback

See merge request espressif/esp-idf!48498
2026-05-21 22:10:00 +08:00
Konstantin Kondrashov
f870ed9d61 feat(efuse): Update efuse table for ESP32H21 2026-05-21 16:29:09 +03:00
wanglei
c7032e78aa fix(esp_rom): both addr and size need align to cache line size 2026-05-21 14:01:16 +08:00
He Binglin
a7b070f306 Merge branch 'bugfix/esp_idf_h4_ci_issues' into 'master'
fix(esp_rom): fix RTC_SLEEP_MODE_REG addr mismatch

Closes IDFCI-11614, IDFCI-11613, IDFCI-11611, IDFCI-11609, IDFCI-11498, IDFCI-11497, IDFCI-11496, IDFCI-11495, IDFCI-11493, IDFCI-11492, IDFCI-11491, IDFCI-11490, IDFCI-11489, IDFCI-11488, IDFCI-11487, IDFCI-11486, and IDFCI-11485

See merge request espressif/esp-idf!48758
2026-05-21 11:42:39 +08:00
Jack
a7fecc1e19 add some fix in the RTC STORE REG comments 2026-05-21 10:41:20 +08:00
hebinglin
84a3cfc0c1 fix(esp_rom): fix RTC_SLEEP_MODE_REG addr mismatch 2026-05-20 19:58:18 +08:00
Jiang Jiang Jian
0f2674f616 Merge branch 'bugfix/fix_ble_coded_phy_rx_bug' into 'master'
fix(coex): fix ble coded phy rx issue when aborted by coex

Closes BT-4291 and BT-4251

See merge request espressif/esp-idf!46962
2026-05-20 19:02:39 +08:00
Nilesh Kale
d8dbc83e7e Merge branch 'feat/enable_ds_hmac_ecdsa_support_for_esp32s31' into 'master'
feat(hal): add ECDSA,  HMAC and Digital Signature support for esp32s31

Closes IDF-14623, IDF-14624, IDF-14621, and IDF-13062

See merge request espressif/esp-idf!48134
2026-05-20 17:44:14 +08:00
wanglei
a52b484faf fix(cache): remove strong symbols in p4 eco0_4 ld
add return value for p4/s31 sync all functions
2026-05-20 17:43:43 +08:00
wanglei
751a75a982 fix(esp_rom): implement cache writeback related apis in iram
avoid critical issues caused by manual cache writeback and conflicting
writes. The issue exist on chips after esp32p4
2026-05-20 17:43:43 +08:00
Jiang Guang Ming
1ac137860c feat(mbedtls): enable PSA threading alt with ROM mbedTLS 2026-05-20 14:15:23 +08:00
Jiang Guang Ming
48418f58a2 feat(esp_rom): merge rom.mbedtls.ld to rom.mbedtls.eco4.ld 2026-05-20 14:15:22 +08:00
Jiang Guang Ming
5d5b8200dc feat(mbedtls): enable ESP32-C2(Rev2.0) ROM crypto for PSA 2026-05-20 14:10:14 +08:00
nilesh.kale
a530aab0a6 feat: enable key manager and HUK support for S31 2026-05-20 10:17:34 +05:30
Aditya Patwardhan
e9a9091b59 feat(hal): add HMAC and Digital Signature support for esp32s31
Co-authored-by: Nilesh Kale <nilesh.kale@espressif.com>
2026-05-20 10:17:34 +05:30
linruihao
df492d5c2f fix(coex): fix ble coded phy rx issue when aborted by coex 2026-05-19 17:52:07 +08:00
Sarvesh Bodakhe
94f226d73b feat(wifi): NAN encrypted datapath (Wi-Fi Aware M1-M4 handshake)
Implement the NAN Data Path encrypted datapath per Wi-Fi Aware v4.0
(§7.1.3.5, §9.5.16):

- Responder + initiator sides of the M1-M4 Shared-Key Descriptor
  exchange, with MIC compute/verify, PTK derivation, and PMK/PMKID
  derivation via PBKDF2-SHA256 over passphrase or pre-shared PMK.
- CSIA / SCIA attribute build + parse, NCS-SK-128 cipher suite.
- Per-NDL security context on ndl_info::security_ctx; per-svc PMK cache.
- ndp_response_indication callback for initiator peer-NDI binding.
- host<->blob ABI migrated from 27 direct esp_nan_* externs to a single
  nan_secure_dp_funcs callback struct in esp_private/wifi.h.
- nan_security.c split out of nan_app.c (~340 lines de-duplicated into
  shared M1-M4 helpers).
- CONFIG_ESP_WIFI_NAN_ENCRYPTED_DATAPATH gates the secure path so non-
  security builds compile out the crypto/handshake code.
- ROM patch (esp32s31): mask ieee80211_encap_esfbuf to match the
  c5/c6/c61 pattern for NAN-capable chips.

Hardening: PMK stack copies zeroized on every return, NDP attribute
parsers bounds-checked, CSID range-checked before shifting, NDL slot
reuse only when handshake state is IDLE, get_csia/scia_len aligned with
their builders on empty input.

API surface: NDP security types moved out of esp_wifi_types_generic.h
into esp_private/wifi.h (internal-only). security pointer dropped from
struct ndp_cb_peer_info. Discovery-side wifi_nan_security_type_t and
the NDP Info callbacks removed (subsumed by csid_bitmap and SSI
respectively).
2026-05-19 11:07:06 +05:30