Files
esp-idf/components/bootloader_support/test_apps
Mahavir Jain 8829e6b864 fix(esp_image_verify): reject segments extending past the partition before hashing
A corrupted segment data_len was only caught by the image length check
after all segments had been checksummed/hashed. On chips with 32-bit cache
mapping (e.g. ESP32-P4 with CONFIG_BOOTLOADER_CACHE_32BIT_ADDR_QUAD_FLASH)
nothing bounds that walk, so a ~1.8 GB data_len trips the task WDT in the
app and the RTC WDT in the bootloader, which then reset-loops on the
corrupted partition.

Check that each segment header and its data lie inside the partition
before processing the segment data.
2026-10-11 14:30:19 +05:30
..