PT-2026-158556
CVE-2026-16667
·
تاريخ النشر
2026-11-24
·
تاريخ التحديث
2026-11-25
الوصف من
CVSS 3.1
6.2
متوسطةالمقاييسAV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
The Cypress/PSoC6 flash-map backend in boot/cypress/cy flash pal/cy flash map.c guards every flash access with assert() against the wrong struct field. flash area read(), flash area write(), and flash area erase() check assert(off < fa->fa off) and assert(off + len < fa->fa off), comparing the area-relative off against the partition's absolute base address fa->fa off instead of its length fa->fa size. Because fa off is a large absolute address, realistic out-of-partition offsets pass the check even in a debug build, and under NDEBUG the asserts are removed entirely. The access then proceeds as memcpy() (or a flash row op) at fa->fa off + off with no enforcement.
The MCUboot core does not bound image-region offsets itself; it relies on flash area read() returning an error. During pre-authentication image validation, bootutil img hash() in boot/bootutil/src/bootutil img hash.c loops over ih hdr size + ih img size + ih protect tlv size — all attacker-controlled header fields of the still-unverified update image — calling flash area read(), and the TLV iterator in boot/bootutil/src/tlv.c reads attacker-derived offsets the same way. An attacker who can stage a crafted image in the secondary/update slot (via OTA, DFU, or serial recovery, depending on the product) declares an oversized ih img size, causing reads far past the partition. A correct backend would reject these and fail validation cleanly; the Cypress backend does not.
The out-of-bounds access is in the source address of the copy — the destination buffer is correctly sized — so there is no memory corruption, no information disclosure to the attacker (the data is only folded into a hash that still fails the signature check), and no authentication bypass. The realistic impact is a bus fault or hang when the computed absolute address lands on an unmapped or peripheral region of the PSoC6 address map: the bootloader crashes instead of rejecting the bad image, an availability (denial-of-service) impact. The defect is specific to the Cypress/PSoC6 port; mainline Zephyr/sim/mynewt backends are unaffected. The identical broken guard in the write/erase primitives is a latent out-of-bounds-write gap, but no attacker-controlled out-of-bounds offset was found to reach those (serial-recovery uploads are bounded by the core), so the reachable memory-safety bug is the out-of-bounds read.
وجدت خطأً في الوصف؟ لديك ما تضيفه؟ لا تتردد في مراسلتنا 👾