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.
Message quality measures whether a commit identifies its scope, purpose, rationale, testing, and supporting references. It does not change the security-severity score.
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 …
Durability/atomicity fix for async persistence: prevents lost MonitorEvents across crashesNew ack-based event lifecycle with random event IDsArchival gating on unacknowledged events to avoid losing preimage/timeout information
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 dat…
API change: claim_funds now takes ClaimFundsOptions, consolidating TLV-known behavior into one pathFailure-packet length bound added to prevent oversized onion error messagesIncoming failure packet truncated at 32 KiB before processing
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 …
Resource exhaustion / denial-of-service via permanent in-memory UTXO reservationIncorrect state tracking in coin-selection wrapperNew API method required for correct lifecycle management (release_utxos)
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, …
Resource lock leak on error pathUTXO lock state inconsistency between selection and confirmationDenial-of-service/funds-unavailability risk from persistent UTXO locks
This commit rewrites how a Lightning wallet talks to Esplora block-explorer servers so that many status checks happen in parallel instead of one at a time. It is a performance/refactoring change. There is no direct evidence in the commit t…
Concurrency/timing change in transaction confirmation logicNew inconsistency check preserved when a previously-confirmed tx is reported unconfirmedAdded defensive error path for missing pre-fetched block status
This change stops the Electrum-based transaction sync client from downloading the very transaction that created an output it is watching. Previously, the client could request that transaction from Electrum, even though a transaction can ne…
Avoids unnecessary Electrum transaction.get requests for watched outputsReduces information disclosure to Electrum server about watched outpointsAdds regression test verifying request suppression
This change improves how the Lightning Dev Kit's Electrum and Esplora transaction-sync clients track watched Bitcoin transactions. Previously, the code ignored the script pubkey (the 'address' associated with a transaction) supplied when r…
Previously ignored `script_pubkey` argument in `register_tx` for transaction watchersElectrum script-history queries previously used an arbitrary transaction output, which could be OP_RETURN and therefore unindexed by some Electrum serversNew logic prefers caller-supplied script pubkey and falls back to non-OP_RETURN outputs
This commit changes how LDK stores pending event notifications. It adds serialization support for several event types that previously were not fully saved to disk, and introduces a helper method so the code can decide which events are wort…
Data-loss prevention: previously non-round-trippable event variants are now fully serialized, avoiding accidental event loss when users serialize Event queues themselvesState-consistency hardening: ChannelManager now explicitly skips events that describe non-surviving restart state, preventing replay of stale eventsDefensive assertion: debug builds assert that every persisted event round-trips to Some(event), catching serialization mismatches
This commit only adds documentation comments to two source files. It explains that certain funding-signing events can become stale if the underlying negotiation fails, and that callers may see specific harmless errors as a result. No code …
This commit fixes a design flaw in LDK's built-in wallet helper where coins selected for a splice-in (or other unclaimed funding) were permanently reserved in memory if the transaction was abandoned. Over repeated failed splices, all spend…
Denial-of-service via UTXO exhaustion from repeated failed splice negotiationsRisk of inability to broadcast fee-bumping/claim transactions due to lack of available UTXOsNew API surface (release_utxos) introduced to mitigate resource leak
This commit removes a fixed-version pin for the honggfuzz fuzzing tool in a continuous-integration script. The project now uses the current release of honggfuzz instead of an older pinned version. There is no change to the actual Lightning…
This commit changes the Rust toolchain used in the continuous integration (CI) fuzzing job from a fixed older version (1.75) to the latest stable release. It is purely a build/test infrastructure change to fix a dependency compatibility is…
This commit makes a previously internal helper function public so that outside developers can build dummy-hop tails for blinded payment paths without recreating the logic themselves. It is an API usability change, not a fix for a known sec…
No security-relevant behavior change in the diffAPI visibility broadened from crate-public to publicCLTV expiry overflow check already present and unchanged
This change adds a safety check in a Bitcoin Lightning Network library (LDK). Previously, if the software tried to verify a peer's commitment signature before it had learned the peer's channel parameters, it could crash with a panic. Now i…
Defensive check added on peer-driven code path to prevent panicMissing counterparty_parameters could previously cause panic during commitment transaction constructionChannel closure returned instead of panic
This commit only changes the wording of an error message sent to peers when a commitment transaction fails validation. It replaces the vague phrase 'Failed to validate our commitment' with the clearer 'Received commitment failed validation…
This commit moves the checks that validate a counterparty's signatures on the holder's commitment and HTLC transactions out of the general channel code and into the signer module (InMemorySigner). Previously, these signature checks were do…
Moved signature validation from channel state machine into signer moduleAdded new tests that corrupt signatures and verify rejectionChanged error message from 'Invalid commitment tx signature from peer' / 'Invalid funding_created signature from peer' to 'Failed to validate our commitment'
This change fixes a Lightning channel splicing bug: when two peers temporarily disconnect during a splice, any half-finished signature the other side already sent is now discarded. Before the fix, that stale signature could be reused after…
State-invalidation bug in multi-step protocol (splice negotiation)Stale cryptographic signature not cleared on disconnectPotential reuse of old commitment state after reconnect
This fix prevents a Lightning channel from being accidentally force-closed. During a splice (a way to resize a payment channel), one side's initial signature could be kept in memory after the peers disconnected. If the peers later reconnec…
State inconsistency: in-memory buffered message not cleared on disconnectDuplicate message processing after reconnectionForce-close consequence for active Lightning channel
This commit is a simple rename of a public function from `matches_invoice_signing_pubkey` to `key_can_sign_invoice`, plus matching updates to its documentation, callers, tests, and changelog. No behavior changed. It is not a security fix.
This commit is a simple rename of a function and its documentation from matches_invoice_signing_pubkey to key_can_sign_invoice. No logic, behavior, or security properties changed. It is a follow-up code-review naming cleanup.
Expand any commit for its author, full message, clarity score, changed files, triage signals, analysis, and source link.
Security candidateDon't use `is_pre_funded_state` to provide an FC monitor updateby Matt Corallo · b7ba29cf · Aug 28, 2025 · 1 fileMessage 91 · StrongModerate 57Details
Commit message · Matt Corallo
Don't use `is_pre_funded_state` to provide an FC monitor update
`Channel::is_pre_funded_state` is used to mean several different things. In this case its used to decide if we should provide a `ChannelMonitorUpdate` marking a channel as closed when we go to force-close it.
Here, we want to capture exactly when the original `ChannelMonitor` is first created, but were doing so indirectly by looking at the channel's state. Worse, `is_pre_funded_state` got updated to be false whenever there is an interctive signing session, which isn't correct for this use - we may have an interactive signing session but have already persisted the original `ChannelMonitor` when we received the first `commitment_signed`.
Instead, we just move to examining `counterparty_next_commitment_transaction_number` which is decrementing for the first time at exactly the time we create the original `ChannelMonitor`, so it provides a much simpler test.
Fixes #3880
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
signing boundary
AI analysis · Moderate 57/100
This change fixes a logic bug in how the Lightning node decides whether to send a 'channel is being force-closed' update to its on-disk channel monitor. Previously, the code used a broad channel-state check that could incorrectly skip sending the update during some interactive funding flows, or send it too early in other cases. The patch replaces that broad check with a precise counter that tracks when the original monitor was first created, ensuring the close update is only generated when a monitor already exists. The practical effect is more reliable recovery of funds during force-closes involving modern interactive channel-opening protocols.
Security candidateDont use `is_pre_funded_state` to short-circuit `shutdown` handlingby Matt Corallo · 759d7aac · Aug 28, 2025 · 1 fileMessage 73 · AdequateLow 42Details
Commit message · Matt Corallo
Dont use `is_pre_funded_state` to short-circuit `shutdown` handling
`Channel::is_pre_funded_state` is used to mean several different things. In this case, its used to skip all the `shutdown` logic as the funding transaction can't possibly have been broadcasted so there's really no ned to try to sign a transaction spending it.
Here, we really want to capture any channel in `NegotiatingFunding` or any V1 channel in `FundingNegotiated` or, finally, any V2 channel in `FundingNegotiated` where we haven't yet sent our signatures (which is not captured in `is_pre_funded_state`).
Instead of a new helper, we just check the states directly in `shutdown` handling.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundary
AI analysis · Low 42/100
This change fixes a logic bug in how the Lightning node decides whether to accept a 'shutdown' message from a peer. Previously, the code used a broad helper called 'is_pre_funded_state' to skip shutdown handling, but that helper did not correctly cover newer V2-style channels that have negotiated funding but not yet sent the node's own transaction signatures. In those cases, a peer could send shutdown and the node might try to run full shutdown logic (including signing a spending transaction) even though the funding transaction was not actually broadcastable yet. The patch narrows the check to the exact channel states where shutdown should be short-circuited.
Lower-priorityAdd test for dummy hop insertionby shaavan · fdf352b7 · Aug 28, 2025 · 3 filesMessage 78 · AdequateInformational 13Details
Commit message · shaavan
Add test for dummy hop insertion
Introduces a test to verify correct handling of dummy hops in constructed blinded paths. Ensures that the added dummy hops are properly included and do not interfere with the real path.
78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
AI analysis · Informational 13/100
This commit only adds new tests and updates an existing test helper. It does not change production code behavior. The tests verify that dummy hops can be inserted into blinded paths and that padded versus compact path formats behave as expected. There is no security fix or vulnerability patch here.
Lower-priorityUpdate Default Blinded Path constructor to use Dummy Hopsby shaavan · 988defb8 · Aug 28, 2025 · 1 fileMessage 73 · AdequateLow 40Details
Commit message · shaavan
Update Default Blinded Path constructor to use Dummy Hops
Applies dummy hops by default when constructing blinded paths via `DefaultMessageRouter`, enhancing privacy by obscuring the true path length.
Uses a predefined `DUMMY_HOPS_COUNT` to apply dummy hops consistently without requiring explicit user input.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Low 40/100
This change improves privacy in Lightning onion messages by adding fake 'dummy hops' to blinded paths by default, making it harder for outside observers to guess how far the real recipient is from the sender. It is a defensive privacy hardening patch, not a fix for an active exploit.
Emit DiscardFunding events for double spent splice transactions
Once we see a splice transaction become locked, we want to emit a `DiscardFunding` event for every alternative funding transaction candidate that may have been negotiated due to RBFs, as they may contain inputs the user has considered "locked" that do not exist in the confirmed transaction. If the channel closes before the splice is locked, we rely on the `ChannelMonitor` to produce these events for us instead.
85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
AI analysis · Low 32/100
This change makes LDK tell users when alternative splice funding transactions are no longer needed, so they can safely reuse the bitcoin inputs. Previously, after a splice locked in, leftover RBF versions of the splice transaction might not have been reported as discardable, which could leave inputs stuck or accidentally double-spent by the user elsewhere. There is no direct exploit here; it is a correctness and usability fix in a splicing feature still behind a compile-time flag.
Sign splice shared input when producing holder tx_signatures
We also remove the `Result` to make it clear that this method does not support async operations yet and rename the method to clarify that it is only intended to be used for the shared input of a splice.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundarycryptography-sensitive pathsigning or wallet path
AI analysis · Moderate 57/100
This commit fixes a missing signature in the Lightning splicing feature. When a user and their peer splice a channel (replace the old funding transaction with a new one), the old funding output is spent as a shared input in the new transaction. Previously, when the holder produced their tx_signatures message, they left the shared_input_signature field as None, even though the protocol requires them to sign that shared input. The commit adds that signature, renames the signer method to make its purpose clearer, and removes the Result return type because the operation is synchronous. It also adds state checks so funding signatures are only accepted when the channel is actually expecting them, and turns a debug-only assertion about signing failures into a logged warning.
This commit tracks all data related to the shared input of a splice, such that a valid witness can be formed upon the splice transaction finalization.
68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundary
AI analysis · Low 35/100
This commit adds support for correctly signing a special kind of Bitcoin transaction input used in Lightning channel 'splicing,' where both parties continue to share an existing funding output while adding or removing funds. Before this change, the code did not know how to build a valid witness (the cryptographic proof that unlocks the shared input) for that shared input. The patch tracks the shared input's position, the order in which the two parties' signatures must appear, and the script that unlocks the funds, then assembles the final transaction witness when both signatures are available. It also adds a small safety check that the transaction ID the caller signed matches the unsigned transaction, to detect malleation.
AI review queuedRun fmt on `can_send_update_fee`by Leo Nash · 37e69dba · Aug 26, 2025 · 1 fileMessage 35 · OpaqueInformational 15Details
Commit message · Leo Nash
Run fmt on `can_send_update_fee`
35/100 · OpaqueMessage clarity
✓ Descriptive subject! No meaningful explanatory body
Why it was queued
second-pass: opaque commit message
AI analysis · Informational 15/100
This commit is purely a formatting cleanup. It removes a `#[rustfmt::skip]` directive and lets rustfmt reformat the `can_send_update_fee` function in the Lightning channel code. No logic, behavior, or security checks were changed.
AI review queuedRun fmt on `validate_update_fee`by Leo Nash · f67143a0 · Aug 26, 2025 · 1 fileMessage 35 · OpaqueInformational 15Details
Commit message · Leo Nash
Run fmt on `validate_update_fee`
35/100 · OpaqueMessage clarity
✓ Descriptive subject! No meaningful explanatory body
This commit is purely a code-formatting cleanup. It removes a `#[rustfmt::skip]` directive and lets rustfmt reformat the `validate_update_fee` function. No logic, behavior, or security checks were changed.
AI review queuedRun fmt on `can_accept_incoming_htlc`by Leo Nash · b58d1d05 · Aug 26, 2025 · 1 fileMessage 35 · OpaqueInformational 15Details
Commit message · Leo Nash
Run fmt on `can_accept_incoming_htlc`
35/100 · OpaqueMessage clarity
✓ Descriptive subject! No meaningful explanatory body
Why it was queued
second-pass: opaque commit message
AI analysis · Informational 15/100
This commit is purely a code formatting cleanup. It removes a `#[rustfmt::skip]` annotation and lets rustfmt reformat the `can_accept_incoming_htlc` function in a single file. No logic, behavior, or security checks were changed.
AI review queuedRun fmt on `validate_update_add_htlc`by Leo Nash · e3ab0ea4 · Aug 26, 2025 · 1 fileMessage 35 · OpaqueInformational 15Details
Commit message · Leo Nash
Run fmt on `validate_update_add_htlc`
35/100 · OpaqueMessage clarity
✓ Descriptive subject! No meaningful explanatory body
This commit is purely a code formatting cleanup. It removes a `#[rustfmt::skip]` annotation and lets rustfmt reformat the `validate_update_add_htlc` function in the Lightning channel code. No logic, behavior, or security checks were changed.
AI review queuedRun fmt on `get_next_commitment_htlcs`by Leo Nash · 59ae9e2a · Aug 26, 2025 · 1 fileMessage 35 · OpaqueInformational 15Details
Commit message · Leo Nash
Run fmt on `get_next_commitment_htlcs`
35/100 · OpaqueMessage clarity
✓ Descriptive subject! No meaningful explanatory body
Why it was queued
second-pass: opaque commit message
AI analysis · Informational 15/100
This commit is purely a code formatting cleanup. It removes a `#[rustfmt::skip]` annotation and lets rustfmt reformat the `get_next_commitment_htlcs` function in the Lightning channel code. No logic, behavior, or security properties of the code were changed.
Lower-priorityRun fmt on `get_next_commitment_value_to_self_msat`by Leo Nash · d267d324 · Aug 26, 2025 · 1 fileMessage 40 · ThinInformational 15Details
Commit message · Leo Nash
Run fmt on `get_next_commitment_value_to_self_msat`
40/100 · ThinMessage clarity
✓ Specific, descriptive subject! No meaningful explanatory body
AI analysis · Informational 15/100
This commit is purely a formatting cleanup. It removes a `#[rustfmt::skip]` annotation and lets rustfmt reformat a single function. The code logic is unchanged; only whitespace, line breaks, and two local `use` imports were added to make the function easier to read.
AI review queuedRemove all `rustfmt::skip` in `tx_builder`by Leo Nash · 3f53f3ac · Aug 26, 2025 · 1 fileMessage 45 · ThinInformational 15Details
Commit message · Leo Nash
Remove all `rustfmt::skip` in `tx_builder`
45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
signing or wallet pathsecond-pass: security-sensitive path
AI analysis · Informational 15/100
This commit is purely a code cleanup: it removes formatting suppression markers (`#[rustfmt::skip]`) from one file and lets the Rust formatter reformat the code. The actual logic, calculations, and behavior of the transaction builder do not change.
Lower-priorityIntroduce parsing logic for DummyTlvsby shaavan · b8d62fc8 · Aug 26, 2025 · 1 fileMessage 45 · ThinLow 28Details
Commit message · shaavan
Introduce parsing logic for DummyTlvs
45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
AI analysis · Low 28/100
This commit adds code to handle 'dummy' hops in onion-routed Lightning messages. Previously, the code had a placeholder TODO noting that dummy hops were not fully supported. The change lets the messenger recognize a Dummy payload, verify its authentication, build the next onion packet, and continue peeling the onion. It also refactors repeated packet-building code into a helper. There is no direct evidence in the commit or supplied references that this fixes an active security vulnerability; it appears to be a feature completion that removes an unhandled edge case.
Lower-priorityIntroduce DummyTlv for blinded path privacyby shaavan · 224ef96a · Aug 26, 2025 · 2 filesMessage 68 · AdequateInformational 12Details
Commit message · shaavan
Introduce DummyTlv for blinded path privacy
DummyTlv represents an empty TLV inserted immediately before the actual ReceiveTlvs in a blinded path. These dummy hops are recursively authenticated like real ones, but carry no content.
By allowing arbitrary dummy hops before the final ReceiveTlvs, we can obscure the true position of the recipient in the route. This makes it harder for a malicious onlooker to infer the actual destination, thereby strengthening recipient privacy.
68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 12/100
This commit adds a privacy feature, not a security fix. It introduces a 'DummyTlv' mechanism that lets senders insert fake, empty hops at the end of a blinded onion route. The goal is to make it harder for an outside observer to guess where the real recipient is in the path, similar to adding decoy stops before your real destination. The change is defensive in nature and does not appear to patch an active vulnerability.
Lower-priorityIntroduce Dummy Hop support in Blinded Path Constructorby shaavan · 4f5b3676 · Aug 26, 2025 · 1 fileMessage 73 · AdequateInformational 19Details
Commit message · shaavan
Introduce Dummy Hop support in Blinded Path Constructor
Adds a new constructor for blinded paths that allows specifying the number of dummy hops. This enables users to insert arbitrary hops before the real destination, enhancing privacy by making it harder to infer the sender–receiver distance or identify the final destination.
Lays the groundwork for future use of dummy hops in blinded path construction.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 19/100
This commit adds a new privacy feature to rust-lightning's blinded message paths. It lets callers insert up to 10 fake 'dummy hops' before the real destination, making it harder for outside observers to guess how far apart sender and receiver are or to identify the final recipient. The change is additive: the old constructor still exists and now delegates to the new one with zero dummy hops. There is no obvious security bug in the patch itself.
Security candidateRename get_inbound_payment_key to get_expanded_keyby shaavan · 4ac1fdad · Aug 26, 2025 · 14 filesMessage 68 · AdequateInformational 15Details
Commit message · shaavan
Rename get_inbound_payment_key to get_expanded_key
The use of ExpandedKey has grown beyond just encrypting inbound payment data-it now also supports BOLT 12 Offers, spontaneous payments, and authentication of various payment metadata.
To reflect this broader purpose, this commit renames the function and updates its documentation accordingly.
This commit is a simple rename of a function from get_inbound_payment_key to get_expanded_key, plus updated documentation. It does not change any behavior, logic, or security properties of the code. The change reflects that the same cryptographic key material is now used for more purposes than just inbound payments, such as BOLT 12 Offers and spontaneous payments.
Lower-priorityCorrect error types for outbound splice checking methodsby Matt Corallo · 2a6501a7 · Aug 26, 2025 · 1 fileMessage 73 · AdequateLow 34Details
Commit message · Matt Corallo
Correct error types for outbound splice checking methods
When doing an outbound splice, we check some of the instructions first in utility methods, then convert errors to `APIError`s. These utility methods should thus either return an `APIError` or more generic (string or `()`) error type, but they currently return a `ChannelError`, which is only approprite when the calling code will do what the `ChannelError` instructs (including closing the channel).
Here we fix that by returning `String`s instead.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Low 34/100
This patch fixes a bug in how error types are used during Bitcoin Lightning channel 'splicing' operations. Splicing lets users add or remove funds from an open channel. Two internal helper functions were returning a 'ChannelError' type, which tells the caller to take specific actions such as warning or closing the channel. But the callers actually convert the result into a normal API error and do not follow those instructions. As a result, a splice that should simply fail with a clear message could instead be misinterpreted as a reason to close the channel or send a protocol warning. The fix changes the helpers to return plain text error strings instead, so the correct failure behavior happens.
Fix empty witness filter in funding_transaction_signed
50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
AI analysis · Moderate 59/100
This commit fixes a simple but significant logic bug in the code that handles signed funding transactions for Lightning channels. The original code accidentally kept only empty witnesses (filtering for witness.is_empty()) instead of keeping the actual non-empty signatures (filtering for !witness.is_empty()). As a result, when a peer sent valid signatures to finalize a channel, the local node would receive an empty list and likely fail to complete the channel setup or produce an invalid transaction. This could disrupt channel opens and, in the worst case, be used to stall or deny service to a node, but it does not directly steal funds because the signatures themselves are still validated elsewhere.
Security candidateAssume splicing input value from channel parametersby Wilmer Paulino · 712b3857 · Aug 26, 2025 · 4 filesMessage 50 · ThinLow 32Details
Commit message · Wilmer Paulino
Assume splicing input value from channel parameters
50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Low 32/100
This commit changes how a Bitcoin Lightning channel signer calculates the value of the old funding output when signing a splice transaction. Instead of accepting the value as a caller-provided argument, it now derives the value from the channel's own stored parameters and adds a check that the transaction input actually matches the expected funding outpoint. This removes an opportunity for a caller to pass a wrong or manipulated input value, which could otherwise cause the signer to produce an invalid or subtly harmful signature.
This is reachable if the event doesn't get handled and a channel reestablish occurs.
55/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Provides an explanatory body
Why it was queued
signing boundary
AI analysis · Low 29/100
This commit removes a debug-only assertion that could crash an LDK node in normal, non-buggy situations. The assertion wrongly assumed a certain event could never be queued twice, but it actually can be if a user doesn't immediately handle the event and a channel reconnect happens. The fix makes the code silently skip re-adding the duplicate event instead of panicking. In release builds this would not crash because it was a debug_assert, but in debug/test builds or custom builds with debug assertions enabled it could cause a denial of service (node shutdown).
Only sign funding transaction on monitor update resumption
The `handle_channel_resumption` path is reachable from both channel reestablish and monitor update completion. Since we only want to sign once we know the monitor update has completed, it's possible we could have unintentionally attempted to sign if we were still pending the monitor update but had a channel reestablish occur.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Moderate 57/100
This change fixes a timing issue in the Lightning Dev Kit where a funding transaction could be signed too early. Previously, the code that decides whether to sign a funding transaction could run both when a channel reconnects and when a pending monitor update finishes. The fix ensures signing only happens after the monitor update has actually completed, preventing a possible invalid or premature signature attempt if a channel reestablish happened while a monitor update was still pending.
Lower-priorityCorrect channel closed detection in payment state replayby Matt Corallo · 3239d671 · Aug 26, 2025 · 1 fileMessage 73 · AdequateModerate 55Details
Commit message · Matt Corallo
Correct channel closed detection in payment state replay
While the case of not having a per-peer-state for a peer that we have a `ChannelMonitor` with should be unreachable by this point in `ChannelManager` loading (we have to at least store the latest update id of the monitor in the peer state), considering a channel as still-live and not replaying its payment state when we don't have a per-peer-state is wrong, so here we fix it.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Moderate 55/100
This commit fixes a logic bug in the Lightning Dev Kit's channel manager. During startup, when the software replays the state of pending payments, it now assumes a channel is closed unless it finds live peer state proving otherwise. Previously it assumed the channel was open unless proven closed. The change prevents a situation where payments tied to a channel with no peer state would be treated as still active and never re-failed or re-claimed, potentially leaving funds stuck.
Lower-priorityStore preimages we learned on chain in case of `MonitorEvent` lossby Matt Corallo · 543cc85e · Aug 26, 2025 · 2 filesMessage 73 · AdequateModerate 57Details
Commit message · Matt Corallo
Store preimages we learned on chain in case of `MonitorEvent` loss
`MonitorEvent`s aren't delivered to the `ChannelManager` in a durable fashion - if the `ChannelManager` fetches the pending `MonitorEvent`s, then the `ChannelMonitor` gets persisted (i.e. due to a block update) then the node crashes, prior to persisting the `ChannelManager` again, the `MonitorEvent` and its effects on the `ChannelManger` will be lost. This isn't likely in a sync persist environment, but in an async one this could be an issue.
Note that this is only an issue for closed channels - `MonitorEvent`s only inform the `ChannelManager` that a channel is closed (which the `ChannelManager` will learn on startup or when it next tries to advance the channel state), that `ChannelMonitorUpdate` writes completed (which the `ChannelManager` will detect on startup), or that HTLCs resolved on-chain post closure. Of the three, only the last is problematic to lose prior to a reload.
When we restart and, during `ChannelManager` load, see a `ChannelMonitor` for a closed channel, we scan it for preimages that we passed to it and re-apply those to any pending or forwarded payments. However, we didn't scan it for preimages it learned from transactions on-chain. In cases where a `MonitorEvent` is lost, this can lead to a lost preimage. Here we fix it by simply tracking preimages we learned on-chain the same way we track preimages picked up during normal channel operation.
73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Moderate 57/100
This commit fixes a bug in rust-lightning where a Lightning node could permanently lose a payment secret (preimage) if the node crashed at an unlucky moment after a channel was force-closed. Losing the preimage means the node cannot claim funds it is owed, effectively losing money. The fix makes the on-chain monitoring component remember preimages it learns from the blockchain, the same way it already remembers preimages learned during normal channel operation, so a restart can recover them even if an in-memory notification was lost.