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

Merge PR 'Ban non-dust HTLCs if dust limit would be breached' (#4890)

Public commit record

What the developer wrote

Authored by Matt Corallo

81/100 · Strong
Merge PR 'Ban non-dust HTLCs if dust limit would be breached' (#4890)

from 2026-08-ban-nondust-htlcs into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/4890
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>
✓ 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 tightens how Lightning payment limits are calculated when transaction fees are high. Previously, the code could allow a non-dust HTLC (a payment large enough to normally appear on-chain) to be offered even when the combined dust-exposure risk pushed the channel past its safety limit. The patch lowers the allowed outbound amount by one millisatoshi in that edge case so the HTLC is treated as dust and rejected, preventing a situation where a miner-fee spike could make an HTLC uneconomical to claim on-chain. The practical effect is a small, defensive correction to fee-based channel safety logic.

Recommended action

Review the full PR #4890 and any related follow-ups to confirm the change covers all channel types and edge cases. Run the updated functional tests and consider adding adversarial test cases where a peer attempts to force an HTLC just above the corrected limit during a feerate spike. Monitor for subsequent commits that extend the same logic to other HTLC directions or commitment transaction variants.

Security signals we found

01

Dust-exposure limiting logic changed in HTLC availability calculation

02

Sub-1-msat adjustment to force non-dust HTLCs below dust threshold when fee risk is high

03

Functional tests rewritten to assert on dust-exposure-derived outbound limit

04

No explicit CVE, advisory, or security-impact statement in commit or supplied references

Risk score

Why this scored 57/100

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