AES image key left on the stack after serial-recovery encrypted-image handling in MCUboot
CVE-2026-127928Published 13 Nov 2026, 00:22 UTC
Real-world risk
0.1/ 10Low
Routine
PreliminaryFrom the CVSS vector only · confidence low
CVSS
2.0
scored by the vendor (CNA), CVSS 3.1
In plain words
No plain-language summary yet. The original description is below.
Original description (from zephyr)
In MCUboot's serial-recovery encrypted-image support (boot/boot_serial/src/boot_serial_encryption.c), decrypt_image_inplace() and boot_image_validate_encrypted() each keep a stack-local struct boot_status. boot_enc_load() writes the plaintext per-image AES key into its enckey[] field. Neither function cleared this structure before returning. In addition, a decrypt failure inside the per-sector loop of decrypt_image_inplace() returned early and skipped the total_out: cleanup, which left the expanded AES key context (enc_data) on the stack as well. The error paths of boot_image_validate_encrypted() similarly skipped boot_enc_zeroize(). The affected code is built when encrypted images (MCUBOOT_ENC_IMAGES, Zephyr CONFIG_BOOT_ENCRYPT_IMAGE) are combined with serial recovery. It runs when an encrypted image is uploaded to the primary slot over the recovery protocol, and when the image list or state is queried while an encrypted image is in the secondary slot. After these functions return, the image's AES content key remains in dead stack memory. An attacker who can later read device RAM, for example through a debug port or retained RAM, can recover it. This weakens the confidentiality of image-encryption keys within the bootloader trust boundary. A recovered key exposes the plaintext of the encrypted firmware image it protects. The device's long-term private decryption key is not exposed. No remote or recovery-protocol channel that returns this memory is known, so exploitation requires a separate memory-read capability.
Am I affected?
| Product | Affected versions (from the sources) | Fixed in |
|---|---|---|
| mcubootNiche | >= 1.9.0, < 2.5.0 | 2.5.0 |
What to do
Update to a fixed version: 2.5.0.
Why this score
| Factor | Value | Evidence | × |
|---|---|---|---|
| Impact | MinorReflected XSS, CSRF with low effect, open redirect, minor leak | From the CVSS vector | 0.30 |
| Attacker position | PhysicalMust touch the device | From the CVSS vector | 0.10 |
| Privileges needed | NoneNo account | From the CVSS vector | 1.00 |
| Victim interaction | NoneNothing | From the CVSS vector | 1.00 |
| Configuration | DefaultOut-of-the-box installs are vulnerable | From the CVSS vector | 1.00 |
| Reliability | HardNarrow race, needs an extra info leak, needs a man-in-the-middle position, or must be chained with another bug | From the CVSS vector | 0.45 |
Threat level T1: Nothing known (× 0.85)
The default for a new disclosure
EPSS 0.1% chance of exploitation in 30 days (percentile 1), as of 2026-12-03.
The arithmetic
- Prerequisites multiplied together0.045
- Threat T1: Nothing known0.850
- 10 × impact 0.3 × prerequisites 0.045 × threat 0.850.115
- Rounded to one decimal between 0.1 and 100.1
Exploitation and evidence timeline
- 13 Nov 2026 Published
- 3 Dec 2026 Risk 0.1 (cvss fallback)
Weakness
CWE-226