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

Don't fail channel if inbound UA breaches counterparty-selected reserve

Public commit record

What the developer wrote

Authored by Leo Nash

73/100 · Adequate
Don't fail channel if inbound UA breaches counterparty-selected reserve

We do not care if our balance drops below the counterparty-selected
reserve upon an inbound `update_add_htlc`. This is the counterparty's
problem.

Hence, we drop the assumption that once our balance rises above the
counterparty-selected reserve, it will always remain above this reserve
for the lifetime of a funding scope.

In the following commit, we make the assumption that the counterparty
does not complain if we push them below our selected reserve when adding
a HTLC, so we accommodate this assumption here.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This commit changes how the Lightning node handles incoming payment requests (HTLCs) that would push the node's own balance below the 'channel reserve' amount chosen by the other party. Previously, the node would reject such HTLCs and close the channel, treating it as a violation. The new behavior accepts these HTLCs, because the developers consider it the counterparty's problem, not theirs. A related safety assertion is now only checked in tests, not in production code. This is a protocol-behavior change rather than a traditional memory-safety or cryptography bug, but it removes a defensive check that previously prevented the local balance from dropping below a reserve threshold on inbound HTLCs.

Recommended action

Review whether removing this reserve check is safe under all channel configurations, especially for zero-reserve or low-reserve channels. Confirm that the counterparty cannot exploit the relaxed check to force the local node into a state where it cannot afford its own commitment transaction fees or where fee pinning becomes easier. Re-enable or replace the removed test with coverage that reflects the new intended behavior, and monitor for any follow-up commits that complete the rationale described in the commit message.

Security signals we found

01

Removal of channel-reserve enforcement on inbound HTLC acceptance

02

Production-only disabling of a balance-reserve invariant assertion (`#[cfg(test)]`)

03

Deletion of a unit test that asserted channel closure for reserve-violating inbound HTLCs

04

Behavioral change in Lightning channel reserve policy, which is a protocol-level economic safeguard

Risk score

Why this scored 47/100

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