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

feat(core/prodtest): Check for device S/N in device certificates.

Public commit record

What the developer wrote

Authored by Andrew Kozlik

62/100 · Adequate
feat(core/prodtest): Check for device S/N in device certificates.

[no changelog]
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope! No meaningful explanatory body
The short version

What changed, and why it matters

This commit adds a production-line safety check in Trezor's internal 'prodtest' firmware. Before writing a device-unique X.509 certificate to the device, the firmware now verifies that the certificate's subject serial number matches the device's own serial number stored in OTP. It also centralizes serial-number reading into a helper function. This is a hardening/validation improvement rather than a fix for an active user-facing vulnerability.

Recommended action

No immediate user action required. Treat as a manufacturing/provisioning hardening change. Reviewers should verify that get_device_sn correctly handles unterminated OTP data and that the certificate parser cannot be confused by multi-RDN subject DNs or unexpected string types.

Security signals we found

01

New certificate subject serialNumber validation against device OTP serial number

02

Refactoring of device serial number retrieval into a bounded helper with MAX_DEVICE_SN_SIZE limit

03

Addition of DER_PRINTABLE_STRING constant for X.509 parsing

04

Documentation updated to enforce ordering of provisioning commands

Risk score

Why this scored 26/100

Our methodology →
Potential impact 5/30
Exploitability 3/25
Stealth signal 3/15
Affected reach 4/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.