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

lnchan: if funding tx is coinbase tx, wait for maturity

Public commit record

What the developer wrote

Authored by SomberNight

73/100 · Adequate
lnchan: if funding tx is coinbase tx, wait for maturity

ref https://github.com/lightning/bolts/commit/17ab3f0dfef50ab98c326a56cb4d109e6f733ab8
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This commit adds a check so that if a Lightning channel is funded by a coinbase transaction (newly created bitcoins from mining), Electrum waits for the standard 100-block maturity period before treating the funding as settled. Before this change, Electrum might have accepted an immature coinbase funding transaction too early, which could lead to an invalid channel state or forced channel closure if the coinbase output later becomes invalid or reorganized. The fix follows a recent update to the Lightning protocol specification.

Recommended action

Review and merge if part of a supported branch. Address the zeroconf FIXME by validating coinbase-funded zeroconf channels before OPEN state, or explicitly disallow them, to avoid forced closures.

Security signals we found

01

Prevents premature acceptance of immature coinbase outputs as Lightning channel funding

02

Aligns implementation with updated Lightning BOLT specification

03

Adds missing coinbase detection helper on Transaction class

04

FIXME comment indicates residual uncertainty around zeroconf handling

Risk score

Why this scored 42/100

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