Caloogy Article
中文

Attack Surface of Hardware Wallets

Date
Nov 14, 2025
Series
Wallet
Reading
4 min
Topics
WalletHardware walletSecure elementFault injection

The one-sentence version

A hardware wallet locks the private key inside a dedicated small device; the private key never enters the computer, and signing is completed internally within the device. It can block most remote attacks (computer infections, browser compromises). However, it has its own attack surface: physical access (fault injection, side-channel attacks), supply chain (swapped or pre-configured devices), user interface (unintelligible screen displays leading to blind signing), and the user themselves (being tricked into revealing the recovery phrase). Understanding these boundaries is essential to using them correctly.

This article has three layers:

  1. Layer 1: The Intuition: A safe can lock out a thief, but it cannot lock out a con artist.
  2. Layer 2: Real-World Use: Kraken Security Labs' voltage glitch research, fake devices, phishing after data leaks, and the Ledger Recover controversy.
  3. Layer 3: Security chips, fault injection, side-channels, firmware verification, and anti-tampering.

Layer 1: The Intuition

1.1 A safe can lock out a thief, but it cannot lock out a con artist

Attacker Can the hardware wallet block them?
Remote hacker controlling your computer Can block: The private key is not on the computer; every signature requires you to press a button on the device to confirm.
Someone who steals the device Basically can block: Requires a PIN; multiple incorrect attempts will wipe the device.
Someone with lab equipment and long-term access to the device Some models cannot block (see 2.1)
Someone selling you a tampered device Cannot block
Someone tricking you into signing an unintelligible transaction on a compromised webpage Cannot block (blind signing)
Someone calling to say "Your wallet is at risk, please provide your recovery phrase" Cannot block

The last three are actually the most common.


Layer 2: Real-World Use


Layer 3: Principles and Engineering

3.1 Secure Element

Standard Microcontroller Secure Element
Design Goal Cheap, general-purpose Resistant to physical attacks (similar to chips in bank cards, passports, and SIM cards)
Protection Minimal Active shielding, voltage/clock/temperature anomaly detection, memory encryption, side-channel resistant design
Certification — Usually holds security certifications like CC EAL5+
Open Source Level Can be fully open source Usually constrained by non-disclosure agreements, making it difficult to fully disclose

This creates a trade-off: Open-source auditability vs. physical attack resistance. Different manufacturers make different choices; some use two chips simultaneously.

3.2 Fault Injection

Creating interference at critical moments of chip operation to make it "calculate one step incorrectly":

The goal is usually to skip a comparison instruction (e.g., "Is the PIN correct?" or "Is read protection enabled?"). Defense: redundant checks, random delays, self-destruction of critical data upon anomaly detection, and writing critical decisions as "pass only if multiple calculations match."

3.3 Side-channel

Instead of reading data directly, information is inferred through power consumption, electromagnetic radiation, or execution time while secrets are being processed. For example, if an elliptic curve scalar multiplication performs an "add" or "no add" operation based on each bit of the private key, the private key's bits can be read directly from the power consumption curve. The defense is constant-time, constant-power implementation (the sequence of operations remains the same regardless of the key) and the use of random masking.

3.4 Firmware and Supply Chain

Risk Protection
Malicious firmware The device only runs firmware signed by the manufacturer; verifies signatures at startup
Swapped devices The device performs authenticity verification with the manufacturer's server upon first boot; anti-tamper packaging
Pre-set recovery phrases Always use only the recovery phrases generated by the device itself; any device accompanied by a "recovery card" should be considered malicious
Second-hand devices Do not buy; or at least fully reset and upgrade the firmware

3.5 The screen is the last line of defense

The most important security feature of a hardware wallet is actually that independent small screen: it is a display channel that is not controlled by the computer (see "Out-of-Band Verification"). However, if the screen only displays a string of hashes or hexadecimal data, the user can only perform blind signing, and this line of defense fails (see "Blind Signing and What You See Is What You Sign," the Bybit incident, and frontend integrity). Therefore, choose a device that supports clear signing (decoding transactions into human-readable language) and actually read the content on the screen.


Summary

Layer Key points
Strengths Blocks remote attacks: private key stays on device, signing requires physical confirmation
Weaknesses Physical access (fault injection, side-channel), supply chain, blind signing, social engineering
Principles Secure elements resist physical attacks; constant-time implementation resists side-channels; firmware signing
Usage Purchase through official channels; use only device-generated recovery phrases; add a passphrase; read the screen