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

Limit legacy multisig to 15 keys maximum, per consensus limits

Public commit record

What the developer wrote

Authored by Salvatore Ingala

85/100 · Strong
Limit legacy multisig to 15 keys maximum, per consensus limits

The redeem script would otherwise be bigger than 520 bytes, which
is the consensus limit; therefore, such scripts are unspendable
and funds sent to such addresses would be lost.

Therefore, we prevent registration altogether.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
The short version

What changed, and why it matters

This commit fixes a bug in Ledger's Bitcoin app where users could register a wallet policy for a legacy P2SH multisig with up to 16 public keys. Such a redeem script would be larger than the 520-byte Bitcoin consensus limit, making the coins unspendable and effectively lost. The patch caps legacy P2SH multisig at 15 keys and rejects anything larger during wallet registration. It does not affect SegWit P2WSH or nested sh(wsh(...)) wallets, which have different limits.

Recommended action

Treat as a security-hardening fix and include in the next firmware/app release. No immediate incident response is required because the issue is self-DoS/funds-loss rather than theft or remote code execution. Users who already registered a 16-key legacy P2SH policy should be advised that funds sent to those addresses are unspendable on-chain and cannot be recovered by the device.

Security signals we found

01

Funds-loss prevention: blocks registration of wallet policies that would produce unspendable outputs

02

Consensus-rule enforcement: aligns with Bitcoin's 520-byte script push limit

03

Input validation hardening: adds explicit bounds check during policy parsing

04

Static assertion: compile-time guarantee that the constant satisfies the size limit

Risk score

Why this scored 58/100

Our methodology →
Potential impact 18/30
Exploitability 8/25
Stealth signal 10/15
Affected reach 8/15
Confidence 9/10
Evidence quality 5/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.