AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Moderate 61 Bitcoin

feat: improve update security, support X Layer, and refresh Zodl wallet integration

Public commit record

What the developer wrote

Authored by ww3512687

67/100 · Adequate
feat: improve update security, support X Layer, and refresh Zodl wallet integration
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope✓ Names security-relevant behavior explicitly! No meaningful explanatory body
The short version

What changed, and why it matters

This firmware update for the Keystone 3 hardware wallet is billed as a security improvement. The most important change is a complete rewrite of the bootloader/firmware update path: it now uses SHA-256 and a signed/length-prefixed 'bootupdate' envelope instead of the older MD5-based verification, and removes an old USB mass-storage auto-reboot behavior that could let a plugged-in host trigger a reboot just by copying a file. The patch also hardens the USB stack against malformed endpoint numbers and oversized control transfers, enables on-chip flash encryption for the external QSPI flash, and improves I2C and random-number error handling. However, the diff is very large and mixes many unrelated features (new wallet icons, X Layer chain support, UI tweaks), so it is hard to be certain every corner case is fixed.

Recommended action

Treat this as a legitimate security-hardening release. Users should install firmware 12.4.0 or later to benefit from the improved update verification and USB hardening. Developers should review the new boot_update.c path for remaining issues: verify that the magic-number search cannot be tricked by attacker-controlled app data, that the SHA-256 hash is authenticated (not just integrity-checked), and that the QSPI AES key/IV read from OTP is properly protected. Additional review of the large USB stack changes is warranted because the patch mixes hardening with unrelated feature work.

Security signals we found

01

Bootloader/firmware update verification upgraded from MD5 to SHA-256 with length-prefixed magic header

02

AUTO_REBOOT_AFTER_COPY_FILE path removed from USB MSC SCSI handler, eliminating host-triggered reboot on file copy

03

USB endpoint address validation added across DCD, USBD core, and class drivers to prevent out-of-bounds EP array access

04

USB EP0/control and bulk OUT receive paths now validate xfer_buff, xfer_count, and remaining length before reading packets

05

CDC class setup handler now whitelists and validates GET_LINE_CODING/SET_LINE_CODING/SET_CONTROL_LINE_STATE/SEND_BREAK requests

06

QSPI external flash encryption enabled (ENABLE_CACHE_AES 1) with AES-128-CBC using OTP-derived key/IV

07

I2C HAL send/receive now propagate I2CIO failure status instead of ignoring return value

08

TRNG driver added with attack-detection flag and NIST-style frequency/runs health checks

09

Heap size reduced from 450 KiB to 440 KiB, possibly to make room for new code/data

010

Version bumped to 12.4.0; changelog explicitly calls out 'Enhanced firmware upgrade security mechanisms'

Risk score

Why this scored 61/100

Our methodology →
Potential impact 18/30
Exploitability 12/25
Stealth signal 8/15
Affected reach 12/15
Confidence 7/10
Evidence quality 4/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.