Skip to content

Back to the catalog

The randomness question at the heart of your hardware wallet
unchained.comarticle

The randomness question at the heart of your hardware wallet

Unchained explains how hardware wallets generate entropy for bitcoin keys, covering PRNG vs TRNG theory, physical TRNG mechanisms (ring oscillator jitter, diode avalanche noise, radio static reuse), and NIST SP 800-90B / BSI AIS-31 certification. It compares entropy sourcing and secure-element chip suppliers (STMicroelectronics, Microchip, Infineon, Espressif, Silicon Labs) across Trezor, Ledger, Coldcard, BitBox02, Foundation Passport, Blockstream Jade and Block Bitkey, and walks through the July 2026 Coldcard firmware bug that silently bypassed its hardware TRNG for five years, causing real bitcoin losses. It also covers manual dice/coin entropy generation for BIP39 seed phrases, the Dark Skippy nonce-leakage attack, and multisig as the primary mitigation against single-device key-generation failures.

TL;DR Deep technical walkthrough of hardware wallet TRNG design, chip sourcing, and the five-year Coldcard firmware bug that silently bypassed its TRNG and leaked bitcoin keys.
Document

What it is

Unchained's explainer on hardware wallet entropy generation, framed around the July 2026 Coldcard firmware bug (already in the summary). The page adds concrete per-device architecture details, a nonce-leakage mitigation naming scheme, and a step-by-step manual seed-generation procedure not captured in the existing summary.

How it works

Per-device entropy design, as documented by Unchained:

  • BitBox02: five combined sources — two hardware TRNGs, a hash of a user-input password, a static factory-set device-unique random number, and entropy from the companion desktop app.
  • Ledger: single source only — entropy from its certified secure element (physical + randomness certification), no companion-app mixing.
  • Trezor / Jade: device TRNG plus companion-app-supplied entropy, intended as a fallback if the internal TRNG is compromised.
  • Foundation Passport: diode avalanche noise circuit built from discrete components with a publicly auditable open-source schematic — unlike competitors' opaque in-chip TRNGs.
  • Blockstream Jade: deliberately skips a certified secure element, using an uncertified general-purpose MCU with radio-assisted TRNG, offset by an external "blind oracle" encryption option they call a virtual secure element.
  • Bitkey: single source from a secure MCU; cannot import seed phrases at all.

Nonce-leakage mitigation: Jade's "anti-exfil" and BitBox's "anti-klepto" features construct transaction-signing nonces partially from a source outside the device, closing the channel the Dark Skippy (2024) attack would otherwise use to exfiltrate the key during signing.

What to do

For manual BIP39 entropy generation (dice/coins/cards), the page gives an actual procedure:

  1. Generate 128 or 256 bits of entropy via fair dice/coins/cards, done privately, recorded offline, never "corrected" for apparent randomness.
  2. Convert bits to BIP39 words using a printed (not on-screen) lookup table — 11 bits per word, 2048-word list.
  3. The final word embeds a checksum (4 bits for 12-word, 8 bits for 24-word phrases) computed via SHA-256, which must be calculated on an offline hardware wallet, never a general computer/phone.
  4. Only BitBox, Passport, Jade, and Coldcard support entering partial entropy and completing the final word during import; Trezor and Ledger require the full phrase; Bitkey doesn't support import at all — relevant when choosing a device for this workflow.

For nonce-leakage defense, enable anti-exfil (Jade) or anti-klepto (BitBox) if using those devices.

Caveats

The page states Dark Skippy–style nonce leakage "has not been seen in the wild" and is a theoretical/disclosed attack, not a confirmed incident. It also notes all proprietary chip TRNG mechanisms (including secure elements) can't be independently verified by consumers — the Trezor Safe 7's TROPIC01 chip is called out as more transparent architecturally, but its TRNG block itself is still not open or auditable.

Organisations named here

  • Android SecureRandom vulnerability
  • anti-exfil
  • anti-klepto
  • BSI AIS-31
  • Coldcard firmware vulnerability (2026)
  • Markettos & Moore (CHES 2009)
  • NIST SP 800-90B

Technologies named here

  • STMicroelectronics TRNG/secure element chips
  • Coldcard
  • Microchip Technology chips
  • Android SecureRandom
  • Infineon Technologies secure elements
  • Milk Sad
  • Espressif Systems chips
  • Trezor
  • Trezor Safe models
  • Silicon Labs secure MCU
  • BIP39 wordlist/lookup table
  • Trezor Safe 7
  • Ledger devices
  • BitBox02
  • BitBox02 Nova
  • Foundation Passport
  • Foundation Passport Prime
  • Blockstream Jade
  • Block Bitkey
  • Bitcoin
  • Ledger

Techniques named here

  • Pseudorandom number generator use
  • True random number generator - ring oscillator jitter
  • True random number generator - diode avalanche noise
  • True random number generator - radio static reuse
  • TRNG exploitation
  • Manual entropy generation
  • Dark Skippy nonce-leak attack
  • Air-gapped communication
  • Multisig wallet arrangement
  • Singlesig key exposure

Threat actors named here

  • Dark Skippy