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

Allow filtered block rescans at the current tip

Public commit record

What the developer wrote

Authored by Elias Rohrer

88/100 · Strong
Allow filtered block rescans at the current tip

A valid same-block replay through Listen could panic OutputSweeper and
ChannelManager because both required every filtered_block_connected call
to advance the chain.

Treat callbacks matching the current tip as rescans, process their
additional transaction data, and skip the duplicate best-block update
while retaining chain-order checks for new blocks.

Fixes #3920

Reported by Project Loupe

Co-Authored-By: HAL 9000
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This commit fixes a bug where replaying the current blockchain block through a normal listener callback could crash two core Lightning components (ChannelManager and OutputSweeper) with a panic. The fix recognizes a same-block replay as a 'rescan,' processes any extra transaction data it carries, and avoids updating the already-current best block. It is a denial-of-service/crash bug triggered by valid, chain-ordered behavior from upstream block sources, not by malformed data.

Recommended action

Apply the patch. If running a node built from an affected commit, ensure the block source cannot replay the current tip, or upgrade promptly. Monitor for any upstream advisories from Lightning Dev Kit.

Security signals we found

01

panic in chain listener callback

02

same-block replay/rescan mishandling

03

assertion failure on valid chain input

04

denial-of-service via crash of ChannelManager/OutputSweeper

05

issue reported by external party (Project Loupe)

Risk score

Why this scored 60/100

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