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

Immediately archive `ChannelMonitor`s for inbound unfuned channels

Public commit record

What the developer wrote

Authored by Matt Corallo

81/100 · Strong
Immediately archive `ChannelMonitor`s for inbound unfuned channels

If a peer opens a channel to us, but never actually broadcasts the
funding transaction, we'll still keep a `ChannelMonitor` around for
the channel. While we maybe shouldn't do this either, when the
channel ultimately times out 2016 blocks later, we should at least
immediately archive the `ChannelMonitor`, which we do here.

Fixes #3384
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This change fixes a cleanup issue in the Lightning Dev Kit: when someone tries to open a channel with you but never actually puts the funding transaction on the blockchain, the software used to keep an unnecessary 'ChannelMonitor' record around for up to about two weeks. After this patch, that leftover record is archived immediately once the channel times out, reducing clutter and avoiding misleading 'claimable balance' reports. It is a reliability/resource issue rather than a direct theft-of-funds bug.

Recommended action

Apply the patch. It is a low-risk cleanup that prevents accumulation of stale monitors and misleading balances from failed inbound channel opens. Monitor for any regressions in balance reporting for legitimately closed channels.

Security signals we found

01

Resource exhaustion / state bloat: stale ChannelMonitors retained for 2016 blocks

02

Informational inconsistency: phantom claimable balances reported for non-existent channels

03

Cleanup of failed inbound channel opens, reducing attack surface for channel-spam DoS

04

No direct loss of funds path identified in the diff

Risk score

Why this scored 35/100

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