LDK
← All projectsLightning Dev Kit

rust-lightning

Composable Rust libraries for building Lightning wallets, nodes, and services.

BitcoinCryptographic librariesLightning NetworkNormal
Repository coverage

1924 commits in the local evidence base

Every captured commit receives deterministic security triage and a separate communication-quality score. Security candidates and broader second-pass signals receive full-patch Ollama analysis.

300security candidates261second-pass queue1606AI analyses
174commits · 30 days
261commits · 60 days
636commits · 180 days
1314commits · 365 days
Backfill bands
Aug 5 → Feb 6819 seen18 candidatesComplete
Feb 6 → Jun 6468 seen16 candidatesComplete
Jun 6 → Jul 6128 seen8 candidatesComplete
Jul 6 → Aug 561 seen3 candidatesComplete
Commit communication

Does the history explain itself?

Message quality measures whether a commit identifies its scope, purpose, rationale, testing, and supporting references. It does not change the security-severity score.

71/100 average clarity
704Strong · 80–100
856Adequate · 60–79
302Thin · 40–59
62Opaque · 0–39
3security candidates with opaque commit messaging
Read the scoring rubric →
Developer activity

Who is changing the project?

Public Git author strings; identities are not independently verified.

DeveloperCommitsCandidatesAnalyzedHigh riskMessage avg.
Matt Corallo58679418876
Elias Rohrer15415153667
auto-pr-bot571823287
Jeffrey Czyz19645182169
Wilmer Paulino15945155169
Valentine Wallace15715145169
Leo Nash11613116162
Vincenzo Palazzo11311183
Joost Jager16324162069
elnosh401434059
shaavan22622069
wpaulino2059082
Analysis record

Published AI watches

Last scanned 38 minutes ago

Informational 15 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Correct FeeEstimator docs on the 253 sat/kW lower bound

This is a documentation-only edit. It corrects a misleading comment in the code that wrongly claimed all fee estimates returned to LDK are forced to be at least 253 satoshis per 1000 weight units. The new comment clarifies that this minimu…

ea2051feby auto-pr-bot+9−31 file
No security note in commit
Moderate 54 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Track splice confirmation while awaiting tx_signatures' (#5570)

This change fixes a bug in Lightning Dev Kit's splicing logic. During a splice, one side can broadcast the new funding transaction as soon as it has the other side's signatures. Previously, if that transaction confirmed on-chain before the…

State-machine inconsistency in channel funding lifecycleMissing chain-source watch for in-flight splice funding transactionPotential failure to send splice_locked after splice confirms during signature exchange
ca778e61by Matt Corallo+245−32 files
No security note in commit
Moderate 63 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Account for current HTLC fees in dust exposure' (#5690)

This change fixes how Lightning nodes calculate the financial risk from tiny ('dust') HTLCs when the current on-chain fee rate is higher than the node's own local fee estimate. Previously, the code only considered a buffered fee rate when …

Incorrect fee exposure accounting for dust HTLCsPotential to accept HTLCs whose commitment/HTLC-success fees exceed their value under current feerateEconomic griefing / forced-channel-closure cost manipulation
cc798f60by Matt Corallo+108−382 files
No security note in commit
Informational 15 AI analysisMessage 91 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Replace cloned array literal with slice::from_ref in reload test' (#5689)

This is a one-line code cleanup in a test file. It replaces a cloned array literal with a slice reference to silence a Rust compiler lint. There is no change to production code, no security fix, and no functional behavior change.

03ca832fby Matt Corallo+1−11 file
No security note in commit
Informational 15 AI analysisMessage 91 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Replace cloned array literal with slice::from_ref in reload test

This is a one-line change in a test file to satisfy a Rust linter warning. It replaces a needless clone of a funding transaction with a reference-based slice construction. There is no functional change, no user-facing behavior change, and …

93e0129cby auto-pr-bot+1−11 file
No security note in commit
Informational 12 AI analysisMessage 91 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Fix CI: rebuild test coin-selection impl and rework reused-ID balance test' (#5684)

This commit is a test-only fix for a broken continuous integration (CI) build. It updates a test mock to match a new function signature and rewrites an existing test to use three nodes instead of two so the test scenario remains valid unde…

17bac68aby Matt Corallo+26−202 files
No security note in commit
Moderate 68 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Guard pending closing signatures before channel_ready' (#5681)

This change fixes a Lightning channel bug where a malicious peer could renegotiate the closing transaction fee while the local node was still waiting for its own signer to produce the final signature. If allowed, the local node might combi…

State-machine guard expansion to prevent fee renegotiation while a closing signature is pendingRisk of combining mismatched signatures across different closing feesRegression test demonstrates malicious peer renegotiation attempt and expected warning rejection
a01273a2by Matt Corallo+169−21 file
No security note in commit
Low 48 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Release wallet UTXOs when FundingBuilder rejects a coin selection' (#5634)

This change fixes a wallet bug in rust-lightning where a UTXO could be selected for a Lightning funding transaction, then rejected because its previous transaction was too large to fit in a Lightning peer message. Previously, that rejectio…

API change to CoinSelectionSource::select_confirmed_utxos adding max_input_prevtx_serialized_lenWalletSync filters UTXOs by prevtx serialized length before selectionFundingBuilder enforces Lightning tx_add_input message-size limit at selection time
56054190by Matt Corallo+148−155 files
No security note in commit
Low 48 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Refuse to pay BOLT 12 invoices with records above experimental range

This commit hardens LDK's BOLT 12 payment logic so it refuses to pay invoices containing very large unknown record types (4 billion and up). These records are legal under the Lightning spec, but LDK doesn't understand them, so the change t…

Defensive refusal to pay invoices with unknown high-numbered TLV recordsReuses existing UnknownRequiredFeatures failure path instead of adding a new oneAdds explicit checks before payment state insertion and route construction
2970372fby auto-pr-bot+106−177 files
No security note in commit
Moderate 64 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Read invoice TLV records above the experimental range

This commit fixes a backward-compatibility bug in LDK's BOLT 12 invoice parser. A previous change had capped the range of 'experimental' TLV record types at 4 billion, but the Lightning spec imposes no upper bound. As a result, invoices cr…

Backward-compatibility regression in deserialization of persisted channel monitorsDenial-of-service via unreadable monitor blocking all channel monitoringSpec compliance fix: TLV record types have no upper bound
9e28db58by auto-pr-bot+133−84 files
No security note in commit
High 74 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Refuse to sign messages that collide with gossip serializations' (#5677)

This change fixes a security issue where a signed text message could be crafted so that its prefixed form looks exactly like a Lightning 'node_announcement' gossip message. Because both use the same double-SHA256 hash and the same signing …

Signature replay / message confusion between signed messages and gossip announcementsForged `node_announcement` signatures via chosen-prefix message constructionNew validation rejects prefixed messages that deserialize as `UnsignedNodeAnnouncement`
ec40e097by Matt Corallo+74−148 files
Vendor flagged security relevance
Low 37 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Retry a single HTLC before abandoning an unfundable batch' (#5406)

This change fixes a corner case in how the Lightning node tries to claim multiple pending HTLCs (small Bitcoin payments locked in a channel) when the wallet cannot fund a single large batch transaction. Previously, if the multi-HTLC batch …

Funds-recovery robustness improvement: prevents premature abandonment of a single unbatched HTLCChange in error-handling arithmetic from checked_sub/saturating_sub with max(1)New unit tests covering both failed and successful singleton HTLC funding paths
643e8684by wpaulino+119−21 file
No security note in commit
Moderate 54 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Refuse to persist fresh monitors that alias archived monitors' (#5645)

This change prevents a Lightning node from accidentally overwriting an archived copy of a channel's security monitor with a brand-new one that happens to use the same identifier. In the old code, if a new channel reused the same identifier…

Data-loss prevention: stops archived ChannelMonitor from being overwritten by a later channel with the same keySafety guard added to both sync and async persistence pathsPersistence refusal surfaces as InProgress/UnrecoverableError rather than silent overwrite
3c606c11by Matt Corallo+298−332 files
No security note in commit
Moderate 52 AI analysisMessage 86 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Handle fee multiplication overflow when merging MPP paths' (#5288)

This change fixes a place in the Lightning payment routing code where adding up fees could overflow the maximum number a computer can store in a 64-bit integer. Previously, the code assumed this could never happen and would crash (panic) i…

Integer overflow in fee computationPreviously unreachable!() panic path reachableMPP path merge could trigger overflow
25f8a740by Matt Corallo+42−171 file
No security note in commit
Low 43 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Resume channels stuck awaiting a completed monitor persistence on reload' (#5610)

This commit fixes a bug where a Lightning node could get stuck after restarting. If the node crashed or restarted while it was still saving the initial channel monitor to disk, and that save later finished in another process, the restarted…

Fixes a state-machine stall on node reload that could leave channels non-functionalRemoves an overstrict assertion that would panic on a legitimate post-reload stateAdds explicit detection of monitor persistence completed in a prior process
11815ed1by Matt Corallo+334−74 files
No security note in commit
Informational 15 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Correct KeysManager docs on spliced channels' remote_key derivation' (#5609)

This change only updates documentation and code comments in the Lightning Dev Kit library. It clarifies that a particular key-derivation setting is fixed when a channel is first opened and is not changed by splicing. No code behavior was a…

83a4d243by Matt Corallo+17−91 file
No security note in commit
Informational 15 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Fix DelayedPaymentKey/HtlcKey from_basepoint docs and document justice tx witness script' (#5596)

This commit only changes documentation comments in two source files. It corrects the wording of how certain public keys are derived in the Lightning protocol and adds details about which witness script a signer must use when creating justi…

Documentation-only changeClarifies key derivation semantics for Lightning commitment transactionsClarifies justice transaction witness script requirements for signers
2f832195by Matt Corallo+44−62 files
No security note in commit
Informational 19 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Document that TokioSpawner requires all of LDK in a tokio context' (#5621)

This change only adds documentation comments to a Rust struct. It does not modify any executable code, so it cannot by itself introduce or fix a security vulnerability. The new text warns developers that using TokioSpawner incorrectly can …

Documentation-only changeNo code logic modifiedNo unsafe blocks added
6e555fa2by Matt Corallo+11−01 file
No security note in commit
High 70 AI analysisMessage 91 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Make custom signers verify holder commitment sigs synchronously' (#5616)

This commit hardens how Lightning Dev Kit handles custom signing modules. Previously, LDK relied on each custom signer to check that the other party's signatures on a holder commitment transaction were valid. The change adds a ready-made v…

New synchronous signature-verification helper for holder commitment transactionsTrait documentation now mandates verification before Ok(()) because LDK acts immediatelyInMemorySigner now validates that holder funding key belongs to signer before signature checks
0e3b6d33by Matt Corallo+324−954 files
Vendor flagged security relevance
Moderate 64 AI analysisMessage 81 · Strong
LDK Lightning Dev Kitrust-lightning BitcoinCryptographic librariesLightning Network

Merge PR 'Refuse channel_ready while the initial funding_signed is pending' (#5612)

This update fixes a corner case in the Lightning Dev Kit where a node could get confused if it received a 'channel_ready' message while still waiting for its own signer to produce the first commitment signature. The patch makes the node re…

State-machine confusion between funding_signed and channel_ready in async signer flowPremature channel_ready could advance counterparty_next_commitment_point before initial commitment is signedPatch closes channel rather than allowing inconsistent commitment state
d68d2235by Matt Corallo+101−12 files
No security note in commit
Repository ledger

Explore captured commits

Expand any commit for its author, full message, clarity score, changed files, triage signals, analysis, and source link.

Lower-priorityMerge PR 'Drop fallback note from ChannelHandshakeConfig docs' (#5035)by tnull · c998a4d3 · Sep 29, 2026 · 1 fileMessage 81 · StrongTriage 0Details
Commit message · tnull

Merge PR 'Drop fallback note from ChannelHandshakeConfig docs' (#5035)

from bot/5028-always-attempt-scid-privacy-nego-397d5a into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5035
Reviewed-by: tnull <tnull@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityDrop fallback note from ChannelHandshakeConfig docsby auto-pr-bot · 8879aa23 · Sep 29, 2026 · 1 fileMessage 81 · StrongTriage 0Details
Commit message · auto-pr-bot

Drop fallback note from ChannelHandshakeConfig docs

@matt asked:

> I don't see a reason to include this. @auto-pr-bot please remove.

Whether we end up with an `option_scid_alias` channel is not something a
caller configures or acts on, and the preceding "when supported by the
counterparty" already says as much, so the extra sentence about falling
back to a channel without the option only repeats it.

Requested-by: @matt
Link: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5028#issuecomment-447986

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Security candidateMerge PR 'Don't track refused monitor updates as pending' (#5030)by Matt Corallo · 47850384 · Sep 28, 2026 · 2 filesMessage 81 · StrongModerate 57Details
Commit message · Matt Corallo

Merge PR 'Don't track refused monitor updates as pending' (#5030)

from 2026-09-refused-upds-not-pending into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5030
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
boot or update pathmerge-commit duplicate discount
AI analysis · Moderate 57/100

This patch fixes a bookkeeping bug in rust-lightning's ChainMonitor. When a channel monitor refuses an update (for example, because the channel is already force-closing), the code used to still record that update as 'pending completion.' Because refused updates are never later marked complete, the pending entry could sit around indefinitely and potentially block follow-up completion actions such as marking a payment as claimed. The change only adds the update to the pending list when the monitor actually accepted it.

Lower-priorityMerge PR 'Always attempt SCID privacy negotiation' (#5028)by Matt Corallo · 1cc8bdab · Sep 28, 2026 · 7 filesMessage 81 · StrongTriage 0Details
Commit message · Matt Corallo

Merge PR 'Always attempt SCID privacy negotiation' (#5028)

from 2026-09-default-scid-privacy into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5028
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityMerge PR 'Fix claim_funds call with ClaimFundsOptions in monitor_tests' (#5032)by joostjager · e2e03186 · Sep 28, 2026 · 1 fileMessage 91 · StrongTriage 0Details
Commit message · joostjager

Merge PR 'Fix claim_funds call with ClaimFundsOptions in monitor_tests' (#5032)

from fix-monitor-tests-claim-funds into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5032
Reviewed-by: joostjager <joostjager@noreply.git.rust-bitcoin.org>

91/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityFix claim_funds call with ClaimFundsOptions in monitor_testsby Chuks Agbakuru · 353e75e8 · Sep 26, 2026 · 1 fileMessage 50 · ThinTriage 0Details
Commit message · Chuks Agbakuru

Fix claim_funds call with ClaimFundsOptions in monitor_tests

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Security candidateMerge PR 'Persistent `MonitorEvent`s' (#4491)by wpaulino · 9a324e72 · Sep 25, 2026 · 12 filesMessage 76 · AdequateModerate 55Details
Commit message · wpaulino

Merge PR 'Persistent `MonitorEvent`s' (#4491)

from valentinewallace/2026-03-persistent-mon-evs into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/4491

76/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
boot or update pathmerge-commit duplicate discount
AI analysis · Moderate 55/100

This commit makes on-chain 'MonitorEvent' notifications durable and replay-safe. Previously, if a node crashed after a ChannelMonitor persisted a block update but before the ChannelManager processed the resulting event, the event could be lost. That could cause a forwarding node to miss an HTLC preimage or timeout, potentially leading to stuck payments or loss of funds. The fix assigns each event a random ID, keeps unacknowledged events in the monitor, replays them after restart, and requires the ChannelManager to acknowledge them once processed. It also prevents monitors from being archived while they still have unacknowledged events.

Security candidateMerge PR 'Fix payment attribution edge cases and simplify claiming' (#5021)by Matt Corallo · ee7c61c2 · Sep 25, 2026 · 22 filesMessage 81 · StrongLow 47Details
Commit message · Matt Corallo

Merge PR 'Fix payment attribution edge cases and simplify claiming' (#5021)

from fulfillment-prerequisites into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5021
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
signing or wallet pathboot or update pathmerge-commit duplicate discount
AI analysis · Low 47/100

This commit refactors how LDK nodes claim incoming Lightning payments. It replaces a separate 'claim with known custom TLVs' method with an options struct passed to the normal claim call, and fixes two edge cases in payment attribution data used for timing analysis: it caps failure-packet size to prevent oversized messages and ensures trampoline-style forwarded claims start fresh attribution rather than reusing downstream data. The changes are mostly defensive correctness fixes rather than an active vulnerability patch.

AI review queuedMerge PR 'release utxos from failed splices' (#4973)by jkczyz · 7220a6fd · Sep 25, 2026 · 3 filesMessage 81 · StrongLow 47Details
Commit message · jkczyz

Merge PR 'release utxos from failed splices' (#4973)

from release-utxos into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/4973
Reviewed-by: jkczyz <jkczyz@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
signing or wallet pathmerge-commit duplicate discountsecond-pass: security-sensitive path
AI analysis · Low 47/100

This change fixes a wallet bookkeeping problem in rust-lightning's built-in coin-selection wrappers. Previously, when a splice attempt failed or coin selection errored after picking UTXOs, those UTXOs stayed marked as 'reserved' in memory and could not be selected again, even though they were no longer actually being used. The patch adds a release_utxos method that callers must invoke when a funded transaction is discarded, and also releases UTXOs automatically if selection fails partway through. Without the fix, a user's wallet could appear to run out of spendable funds after failed splices or selection errors.

AI review queuedRestore `Wallet` UTXO locks when coin selection fails afterwardsby elnosh · 81afd9ca · Sep 25, 2026 · 1 fileMessage 73 · AdequateLow 49Details
Commit message · elnosh

Restore `Wallet` UTXO locks when coin selection fails afterwards

`Wallet` locks the UTXOs it selects before fetching the change script
and the previous transactions from the `WalletSource`. If either of
those fails, the selection is discarded but the UTXOs stay locked.
Record the previous lock entry of every UTXO a selection locks and put
it back if the selection fails afterwards.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing or wallet pathsecond-pass: security-sensitive path
AI analysis · Low 49/100

This commit fixes a bug in the wallet's coin-selection code. When the wallet picked UTXOs to spend, it locked them immediately so they couldn't be reused. But if a later step—fetching the change address or the previous transaction—failed, the selection was thrown away while the UTXOs stayed locked. That could permanently or temporarily freeze funds that should have been spendable. The patch records each UTXO's prior lock state and restores it when the later step fails, and adds tests proving both newly locked and previously-locked UTXOs are handled correctly.

AI review queuedHold back HTLC monitor events while updates are in-flightby Valentine Wallace · 8c17c4a9 · Sep 23, 2026 · 3 filesMessage 73 · AdequateModerate 57Details
Commit message · Valentine Wallace

Hold back HTLC monitor events while updates are in-flight

A ChannelMonitor applies a ChannelMonitorUpdate in-memory before the update
has been durably persisted, and may queue a MonitorEvent::HTLCEvent based on
the update's contents.

Acting on such an event before the update which generated it is persisted will
become unsafe when we begin generating monitor events for off-chain HTLC
failures: if we crash and lose the update that triggered the monitor event, we
lose the counterparty's revocation of the state containing the HTLC, yet we may
have already told the user that the payment failed.

Thus, have the ChainMonitor hold back a monitor's HTLC events while it has any
in-flight updates, and document the same requirement on
Watch::release_pending_monitor_events. Other monitor events, e.g. channel
closures, are still released immediately.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
second-pass: broader security terminology
AI analysis · Moderate 57/100

This commit fixes a crash-recovery safety issue in the Lightning Dev Kit's channel monitor. Before the fix, the code could report a failed payment to the user based on a state change that had not yet been saved to disk. If the program crashed right after reporting the failure, it might restart without the counterparty's revocation that justified the failure, potentially leading to inconsistent payment state. The fix delays payment-failure notifications until the underlying state change has been durably saved.

Lower-priorityMerge PR 'Claim HTLC when preimage appears after queued fail-back' (#5018)by wpaulino · 0a2b003e · Sep 23, 2026 · 2 filesMessage 81 · StrongTriage 0Details
Commit message · wpaulino

Merge PR 'Claim HTLC when preimage appears after queued fail-back' (#5018)

from 2026-09-claim-after-queued-fail into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5018
Reviewed-by: wpaulino <wpaulino@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityReject underfunded LSPS2 forwardsby Elias Rohrer · 6f621695 · Sep 23, 2026 · 4 filesMessage 58 · ThinTriage 8Details
Commit message · Elias Rohrer

Reject underfunded LSPS2 forwards

An intercepted HTLC's `expected_outbound_amount_msat` comes from the
payer's own onion, yet we sized JIT channel opens and forwards from it
without checking it against what the HTLC delivered. A payer could
declare a large amount, send almost nothing, and have us spend our own
funds.

Fail such HTLCs back at interception instead, leaving the client's JIT
channel and its queued payments untouched. HTLCs a prior version had
already queued keep their unvalidated amounts.

Thanks to Aziz Pulatov for reporting this issue.

Co-Authored-By: HAL 9000

58/100 · ThinMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context
Why it was queued
defensive validation
Lower-priorityMerge PR 'Add release notes for 0.2.6' (#5019)by Matt Corallo · 8b310759 · Sep 22, 2026 · 2 filesMessage 76 · AdequateTriage 0Details
Commit message · Matt Corallo

Merge PR 'Add release notes for 0.2.6' (#5019)

from 2026-09-0.2.6-relnotes into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5019
Reviewed-by: tankyleo <tankyleo@noreply.git.rust-bitcoin.org>

76/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
documentation-only discountmerge-commit duplicate discount
Lower-priorityMerge PR 'Test duplicate HTLC CLTV sorting' (#5014)by Matt Corallo · 6cc47c1c · Sep 21, 2026 · 1 fileMessage 91 · StrongTriage 0Details
Commit message · Matt Corallo

Merge PR 'Test duplicate HTLC CLTV sorting' (#5014)

from fix/duplicate-htlc-cltv-sorting into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5014
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

91/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityTest duplicate HTLC CLTV sortingby elnafateh · e978609e · Sep 19, 2026 · 1 fileMessage 70 · AdequateTriage 0Details
Commit message · elnafateh

Test duplicate HTLC CLTV sorting

Co-Authored-By: Codex <codex@openai.com>

70/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body✓ Mentions testing or verification
Security candidateDon't track refused monitor updates as pendingby Valentine Wallace · ada0cb7a · Sep 18, 2026 · 2 filesMessage 68 · AdequateModerate 66Details
Commit message · Valentine Wallace

Don't track refused monitor updates as pending

When a monitor update is rejected by the monitor (e.g. a stale commitment
update applied after funding spend), it's possible that that update modified
the monitor's state. Therefore, the ChainMonitor will respond by persisting the
entire monitor and not persisting the individual rejected update.

However, prior to this patch, if the above whole-monitor-persist returned
InProgress, the monitor would erroneously track the rejected monitor update as
pending-persist, even though that update was never handed to the persister in
the first place, so implementations would never know to call
channel_monitor_updated with the rejected update's ID.

This dangling pending update can then block emission of
MonitorEvent::Completed, blocking ChannelManager's completion actions (e.g.
PaymentClaimed) until restart. In the case of payment forwards, if this bug
blocked the resumption of another channel, it could lead to an HTLC timing out
and a force close.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
boot or update path
AI analysis · Moderate 66/100

This patch fixes a bookkeeping bug in rust-lightning's ChainMonitor. When a monitor update is rejected (for example, because the channel funding has already been spent), the code may persist the entire monitor instead of the individual update. If that full-monitor save was still in progress, the system incorrectly recorded the rejected update as 'pending completion.' Because the rejected update was never actually handed to the persister, it would never complete, leaving a dangling pending entry. That could stall important channel events, and in payment-forwarding scenarios could contribute to an HTLC timeout and a forced channel closure.

Lower-priorityMerge PR 'Keep funding inherited from a pending splice out of `DiscardFunding`' (#4993)by Matt Corallo · ccd7f501 · Sep 18, 2026 · 11 filesMessage 81 · StrongTriage 0Details
Commit message · Matt Corallo

Merge PR 'Keep funding inherited from a pending splice out of `DiscardFunding`' (#4993)

from 2026-09-splice-discard-funding-pending into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/4993
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityMerge PR 'Re-record on-chain preimage claims post-reorg' (#5007)by wpaulino · 56b95944 · Sep 18, 2026 · 2 filesMessage 81 · StrongTriage 0Details
Commit message · wpaulino

Merge PR 'Re-record on-chain preimage claims post-reorg' (#5007)

from 2026-09-keep-onchain-entry-post-reorg into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5007
Reviewed-by: wpaulino <wpaulino@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityRe-record on-chain preimage claims post-reorgby Valentine Wallace · a619a083 · Sep 17, 2026 · 2 filesMessage 68 · AdequateTriage 0Details
Commit message · Valentine Wallace

Re-record on-chain preimage claims post-reorg

When a counterparty's on-chain preimage claim of an HTLC first confirms, the
`ChannelMonitor` records both an `OnchainEventEntry` to monitor for the claim's
anti-reorg safety and a `MonitorEvent` to surface to the `ChannelManager` for
the claim.

If this on-chain claim was reorged out and then reconfirmed before the manager
had a chance to process the monitor event, prior to this patch the monitor
would drop the on-chain event entry when it saw the reorg and then fail to
re-add it when the claim re-confirmed on chain, causing a phantom `Balance`
for the HTLC to stay forever and prevent the monitor from being archived.

Here we stop gating the `OnchainEventEntry` queueing on whether a monitor event
is already present for the claim, ensuring a new entry will be pushed when the
reorged claim re-confirms.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-priorityClaim HTLC when preimage appears after queued fail-backby Valentine Wallace · 0f86dade · Sep 17, 2026 · 2 filesMessage 85 · StrongTriage 0Details
Commit message · Valentine Wallace

Claim HTLC when preimage appears after queued fail-back

When a forwarded HTLC's downstream channel is on chain and the upstream
HTLC is about to expire, ChannelMonitor queues a failure of the HTLC
upstream to avoid the upstream channel force-closing.

If the downstream counterparty then claims the HTLC on chain with the preimage
before the ChannelManager has picked up that queued failure, we should drop the
queued failure and queue success instead. Prior to this patch, we would instead
ignore the late success claim and fail the HTLC backwards.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Lower-priorityDRY monitor on-chain claim event pushby Valentine Wallace · ef7267cd · Sep 17, 2026 · 1 fileMessage 60 · AdequateTriage 0Details
Commit message · Valentine Wallace

DRY monitor on-chain claim event push

This hunk will be touched in the next commit, so pre-factor it slightly now.

60/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body
Lower-priorityMerge PR 'Regenerate the unicode category tables from UnicodeData 18.0.0' (#5006)by Matt Corallo · dbb31315 · Sep 17, 2026 · 1 fileMessage 81 · StrongTriage 0Details
Commit message · Matt Corallo

Merge PR 'Regenerate the unicode category tables from UnicodeData 18.0.0' (#5006)

from bot/5003-unicode-listing-out-of-date-unic-4146dd into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/5006
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount
Lower-priorityRegenerate the unicode category tables from UnicodeData 18.0.0by auto-pr-bot · 4a89f95e · Sep 17, 2026 · 1 fileMessage 81 · StrongTriage 0Details
Commit message · auto-pr-bot

Regenerate the unicode category tables from UnicodeData 18.0.0

@matt asked:

> @auto-pr-bot please fix.

The nightly `check_unicode` workflow regenerates
`lightning-types/src/unicode.rs` from the latest published
`UnicodeData.txt` and files an issue when the result differs from what is
committed. It has been failing since Unicode 18.0.0 was published, so the
tables were still those of 17.0.0, the version they were originally
generated from.

Only the `Cn` (Unassigned) table moves: 18.0.0 assigns codepoints that
`PrintableString` was therefore still replacing with U+FFFD, and unassigns
none. The `Cc`/`Cf`/`Cs`/`Co` and `Zl`/`Zp` tables come out byte-identical,
so no previously-printable character starts being filtered.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

Fixes #5003

Requested-by: @matt
Link: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/issues/5003#issuecomment-446398

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Lower-priorityMerge PR 'Emit SpliceNegotiationFailed for pending negotiation upon force closing' (#4988)by Matt Corallo · 64db7eeb · Sep 16, 2026 · 4 filesMessage 81 · StrongTriage 0Details
Commit message · Matt Corallo

Merge PR 'Emit SpliceNegotiationFailed for pending negotiation upon force closing' (#4988)

from missing-splice-failed-force-close into main

Reviewed-on: https://git.rust-bitcoin.org/lightningdevkit/rust-lightning/pulls/4988
Reviewed-by: Matt Corallo <matt@noreply.git.rust-bitcoin.org>

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
merge-commit duplicate discount