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 24 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-priorityQueue a splice on a channel with an inherited splice until it locksby Jeffrey Czyz · 1127a38a · Jul 9, 2026 · 2 filesMessage 73 · AdequateLow 33Details
Commit message · Jeffrey Czyz

Queue a splice on a channel with an inherited splice until it locks

A pending splice negotiated before an upgrade from a prior LDK version
(e.g. 0.2) comes back without its feerate or our contribution: 0.2
persists neither and drops the odd TLVs that carry them. Without them the
inherited splice cannot be RBF'd.

Rather than refuse to splice the channel, leave the RBF feerate floor unset
so the new splice is queued and begins as a fresh splice once the inherited
splice locks -- the same path taken whenever a contribution cannot replace
the pending candidate via RBF, such as on a zero-conf channel.

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

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Low 33/100

This commit fixes a compatibility edge case when users upgrade from an older version of LDK (0.2) while a channel splice is still pending. The older version did not save enough details about the splice, so after upgrading the software could not safely continue or replace that splice. The fix makes the newer code recognize the missing information and queue a fresh splice instead of refusing or crashing. It is a robustness improvement for cross-version upgrades, not a remotely exploitable vulnerability.

Lower-priorityCompute the minimum splice RBF feerate via PendingFundingby Jeffrey Czyz · 5137c126 · Jul 9, 2026 · 1 fileMessage 73 · AdequateInformational 14Details
Commit message · Jeffrey Czyz

Compute the minimum splice RBF feerate via PendingFunding

splice_channel derived the pending splice's minimum RBF feerate by mapping
a standalone helper over the prior round's feerate, shadowing the helper's
name with the resulting local. Encapsulate the derivation as
PendingFunding::min_rbf_feerate, mirroring the FundingTemplate accessor it
feeds, and keep the formula as an associated function for the call sites
that derive the prior feerate differently.

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

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 14/100

This commit is a pure code cleanup: it moves a small fee-calculation helper for Lightning splice RBF (replace-by-fee) transactions into a struct method and renames it. The actual arithmetic formula and the places that use it stay exactly the same. There is no change to behavior, no bug fix, and no security issue introduced or fixed.

Lower-priorityAdd pending changelog entry for PR 4687by Jeffrey Czyz · 0af1ebbb · Jul 9, 2026 · 1 fileMessage 45 · ThinInformational 15Details
Commit message · Jeffrey Czyz

Add pending changelog entry for PR 4687

45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
documentation-only discount
AI analysis · Informational 15/100

This commit only adds a changelog text file describing a previously merged feature (PR 4687). It does not change any source code, build scripts, tests, or documentation that affects program behavior. There is no security-relevant change to assess.

Lower-priorityExpose pending splice details in ChannelDetailsby Jeffrey Czyz · cb77c1c3 · Jul 9, 2026 · 6 filesMessage 68 · AdequateInformational 20Details
Commit message · Jeffrey Czyz

Expose pending splice details in ChannelDetails

A channel may have splice attempts in progress: a contribution we have
committed but not yet begun negotiating, one under negotiation with the
counterparty, and any negotiated transactions (the original splice and
any RBF replacements) waiting on confirmations. This state was only
observable through events and the broadcaster's
TransactionType::InteractiveFunding, neither of which can be queried on
demand.

Add an optional splice_details field to ChannelDetails. Every splice or
RBF round on the channel that has not yet locked is reported as a
candidate, each carrying our contribution to it (if any) and a status
giving the stage it has reached, from a contribution awaiting quiescence,
through negotiation, to a signed transaction awaiting confirmations. This
also reports the single candidate that has confirmed, with its
confirmation progress and whether we have sent splice_locked for it, and
the txid of any splice_locked received from the counterparty.

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

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 20/100

This commit adds a new read-only API field that lets users query the status of in-progress channel splice operations on demand. It does not change protocol behavior, permissions, or how funds are handled; it only exposes internal state that was previously visible only through event notifications. There is no indication this introduces a security vulnerability.

Lower-priorityRemove redundant witness program checkby Abeeujah · 47a090aa · Jul 8, 2026 · 1 fileMessage 68 · AdequateInformational 19Details
Commit message · Abeeujah

Remove redundant witness program check

With rust-bitcoin `0.32.4` release, verifying a script is a witness
program delegates to `Script::witness_version`, This makes adding
`Script::is_witness_program` check alongside a witness_version check
redundant.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 19/100

This is a small code cleanup that removes an unnecessary duplicate check when validating Bitcoin output scripts during Lightning channel funding. The old code first asked 'is this a witness program?' and then separately asked 'what is its witness version?' The newer version of the underlying rust-bitcoin library makes the first question redundant, so the patch drops it. There is no functional behavior change intended.

Lower-priorityAdd amounts to HTLC locatorsby benthecarman · 588054e4 · Jul 8, 2026 · 6 filesMessage 68 · AdequateInformational 19Details
Commit message · benthecarman

Add amounts to HTLC locators

Include per-HTLC amounts in `PaymentForwarded` locators so callers can
account for each channel independently when a forward uses multiple
incoming or outgoing HTLCs.

AI-assisted-by: OpenAI Codex

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 19/100

This commit adds the HTLC amount (in milli-satoshis) to the data structures LDK uses to locate forwarded payments. It is a feature/enhancement change: callers of the PaymentForwarded event can now see per-HTLC amounts when a forward involves multiple incoming or outgoing HTLCs. There is no security vulnerability in the diff; it only enriches event metadata and updates serialization, tests, and test helpers accordingly.

Lower-priorityCorrect CHANGELOG dates on 0.2.1 and 0.2.2by Matt Corallo · 253018ca · Jul 8, 2026 · 1 fileMessage 45 · ThinInformational 15Details
Commit message · Matt Corallo

Correct CHANGELOG dates on 0.2.1 and 0.2.2

45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
documentation-only discount
AI analysis · Informational 15/100

This commit only fixes two release dates in the project's CHANGELOG.md file, changing the years for versions 0.2.1 and 0.2.2 from 2025 to 2026. There are no code changes, no security fixes, and no functional impact.

AI review queuedPanic on unexpected chanmon monitor eventsby Joost Jager · 3b46ec98 · Jul 8, 2026 · 1 fileMessage 80 · StrongInformational 18Details
Commit message · Joost Jager

Panic on unexpected chanmon monitor events

Monitor event draining expects BumpTransaction events, which the
harness must mine, plus SpendableOutputs and DiscardFunding events,
which it intentionally ignores because it does not model an external
wallet. Make that whitelist explicit by panicking on any other monitor
event instead of silently ignoring it.

80/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Why it was queued
second-pass: broader security terminology
AI analysis · Informational 18/100

This change only affects an internal fuzz-testing harness, not production code. It makes the test harness crash with a clear error message if it encounters a ChannelMonitor event it doesn't know how to handle, instead of silently ignoring it. This helps fuzz tests catch unexpected behavior but does not create a security vulnerability in real Lightning nodes.

Lower-priorityStore splice contributions with their negotiated candidatesby Jeffrey Czyz · 707d65ce · Jul 7, 2026 · 1 fileMessage 85 · StrongLow 32Details
Commit message · Jeffrey Czyz

Store splice contributions with their negotiated candidates

PendingFunding tracked our splice contributions in a compact list
implicitly aligned to the tail of the negotiated candidates, with the
in-flight negotiation round's contribution as the implicit last entry.
Every consumer had to re-derive this positional relationship, which is
easy to get wrong -- e.g., attributing an in-flight round's
contribution to a completed counterparty-only candidate.

Instead, store each candidate's contribution with the candidate itself
and give the in-flight round's contribution its own field, making such
misattribution unrepresentable. The contributions still form a suffix
of the candidates -- once a round includes our contribution, every
subsequent round carries it forward (possibly feerate-adjusted) so the
splice intention is never lost -- which is now asserted when a round
completes.

Serialize this so a single (non-RBF) pending splice stays loadable by
LDK 0.2 while RBF is refused loudly. 0.2 predates per-candidate
contributions, the in-flight contribution, and the last-negotiated
feerate, so writing any of them in an even (required) TLV would make 0.2
refuse even a single splice it can otherwise operate. The legacy TLV 3
therefore carries only the first candidate's funding -- the single-splice
view 0.2 reads -- while the full candidate list, the in-flight
contribution, and the feerate go in odd TLVs that 0.2 skips. An even gate
TLV is written only when there is more than one negotiation round (RBF),
so 0.2 loads single splices and refuses RBF, which it cannot operate.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <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
AI analysis · Low 32/100

This commit refactors how a Lightning node keeps track of money it adds during splice and RBF (fee-bump) negotiations. Previously, the node's own contributions were stored in a separate list that had to be manually aligned with negotiated funding candidates, which the commit message says was 'easy to get wrong.' The change bundles each contribution with the candidate it belongs to and adds explicit checks to prevent misattribution. It also carefully preserves backward compatibility so older LDK versions can still load simple single splices but will refuse to load more complex RBF states they cannot safely handle.

Security candidateRequire `htlc_value_satoshis` in [pending] `HTLCUpdate`sby Matt Corallo · 40957aad · Jul 7, 2026 · 4 filesMessage 85 · StrongLow 25Details
Commit message · Matt Corallo

Require `htlc_value_satoshis` in [pending] `HTLCUpdate`s

In 0.0.100 we started tracking the amounts being claimed in
`OnchainEvent::HTLCUpdate` and then also in
`MonitorEvent::HTLCUpdate`'s `HTLCUpdate`. It was always set, but
stored as an `Option` to support further downgrade. Because these
objects time out after `ANTI_REORG_DELAY` (6) blocks, there's not
really much reason to keep supporting backwards compatibility to
upgrade with such objects without an amount.

In 0.0.115, we started providing the amount in `PaymentForwarded`.
For whatever reason, despite the event only being generated in
cases where we had amounts, the field was added as an `Option`.

Still, in 0.0.118 we started generating them from both off-chain
and on-chain claims. For off-chain claims it was always set, but
for claims which originated from on-chain claims, the amounts came
from the `MonitorEvent::HTLCUpdate` and thus were always an
`Option`. If we no longer care about `MonitorEvent::HTLCUpdate`'s
without a claim amount, we no longer need to worry about
`Event::PaymentForwarded` either. Thus, we make it required here
as well.

85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Why it was queued
update trust
AI analysis · Low 25/100

This commit removes the 'Option' wrapper from several HTLC amount fields, making them required instead of optional. It is a cleanup/refactoring change that simplifies the code by assuming the amount is always known. The commit message frames this as removing legacy downgrade support, not as fixing a security bug. There is no direct evidence in the diff of an exploitable vulnerability.

Security candidateUse a builder for sign_interactive_funding_tx argumentsby Jeffrey Czyz · ed250c02 · Jul 7, 2026 · 1 fileMessage 78 · AdequateInformational 15Details
Commit message · Jeffrey Czyz

Use a builder for sign_interactive_funding_tx arguments

The signing helper had accumulated several boolean/option parameters beyond
the two nodes, so call sites passed opaque positional `false`s and bare
`None`s whose meaning was unclear without consulting the signature.

Replace the two overloaded functions with a single `sign_interactive_funding_tx`
taking a `SignInteractiveFundingTxArgs` builder, mirroring `PassAlongPathArgs`:
`new(initiator, acceptor)` defaults to a first-attempt splice on a confirmed
channel with no acceptor contribution, and each non-default behavior is opted
into by a named method (`zero_conf`, `with_acceptor_contribution`, `replacing`).

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

78/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Names security-relevant behavior explicitly
Why it was queued
signing boundary
AI analysis · Informational 15/100

This commit is a code cleanup inside the project's test suite. It replaces a helper function with several hard-to-read positional arguments (like bare `false` and `None`) with a 'builder' pattern that names each option. This makes the tests easier to read and maintain, but it does not change any production behavior or fix a security bug.

Lower-priorityFilter stale closed hop sends in chanmon fuzzby Joost Jager · 53b399c4 · Jul 7, 2026 · 1 fileMessage 78 · AdequateInformational 15Details
Commit message · Joost Jager

Filter stale closed hop sends in chanmon fuzz

Hop sends can route over an open SCID while LDK's non-strict
forwarding still selects a parallel channel that the harness has
already tracked closed but a node still lists. Skip those API sends
until the stale listing clears, while keeping the existing open-id
checks for fully dropped closed channels.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Informational 15/100

This change only modifies a fuzzing test harness, not the production Lightning Dev Kit code. It adds a filter so that simulated multi-hop payments skip test scenarios where the harness's view of a closed channel is temporarily out of sync with a node's own channel list. This prevents the fuzzer from generating misleading test cases where a payment appears to stall because the test state is inconsistent. It does not fix a vulnerability in real LDK software and cannot be exploited by users or attackers.

Lower-priorityTolerate stale STFU warnings in chanmon fuzzby Joost Jager · 13c97eb5 · Jul 7, 2026 · 1 fileMessage 78 · AdequateInformational 15Details
Commit message · Joost Jager

Tolerate stale STFU warnings in chanmon fuzz

When stale message events are delivered after a channel close, the
recipient can respond with the expected STFU warning instead of the
control error path. Treat that warning as expected for channels the
harness already tracks closed, while documenting that stale events
should still be delivered so handlers exercise their normal error paths.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Informational 15/100

This commit changes only a fuzzing test harness (a tool that randomly exercises code to find bugs). It teaches the test harness to accept a specific warning message as expected when a test delivers an outdated 'STFU' message after a channel is already closed. It does not change the actual Lightning protocol handling code, so it cannot directly affect real users or funds.

Security candidateln: persist the paid BOLT 12 invoice and build payer proofsby Vincenzo Palazzo · 580c9bc8 · Jul 6, 2026 · 4 filesMessage 83 · StrongLow 25Details
Commit message · Vincenzo Palazzo

ln: persist the paid BOLT 12 invoice and build payer proofs

Carry the paid `Bolt12Invoice` through the outbound payment so it survives
restarts, and surface it as a `PaidBolt12Invoice` on `Event::PaymentSent` so the
payer can build a payer proof. The payer signing key is re-derived from the
invoice's own payer metadata, so no extra key material is stored.

`PaidBolt12Invoice` now lives in `offers::payer_proof`; existing async payment
tests and a test helper are updated to construct it via the new API. Adds an
end-to-end test that pays a BOLT 12 offer and builds + verifies a payer proof
from the resulting `Event::PaymentSent`.

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

83/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
signing boundary
AI analysis · Low 25/100

This commit is a feature addition, not a vulnerability fix. It extends rust-lightning's BOLT 12 payment support so that when a wallet pays a BOLT 12 invoice, the paid invoice is saved through retries and restarts and is later exposed in the PaymentSent event as a PaidBolt12Invoice. The wallet can then use that object to build a cryptographic 'payer proof' that selectively discloses invoice fields to prove to a third party that it paid. The payer signing key is re-derived from data already in the invoice, so no extra secret key storage is needed. There is no indication in the commit that this fixes a security bug; it is new functionality with tests.

AI review queuedfuzz: add a payer proof deserialization targetby Vincenzo Palazzo · 1817d621 · Jul 6, 2026 · 5 filesMessage 78 · AdequateInformational 15Details
Commit message · Vincenzo Palazzo

fuzz: add a payer proof deserialization target

Throw arbitrary bytes at `PayerProof::try_from` to exercise the merkle-root
reconstruction and the deserialization path together.

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

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidencesecond-pass: broader security terminology
AI analysis · Informational 15/100

This commit only adds a new fuzz test target. Fuzz tests are automated tools that throw random or crafted input at a piece of code to look for crashes or bugs. The commit does not change any production code, protocol behavior, or user-facing functionality, so it does not introduce or fix a security issue by itself.

Security candidaterefactor(offers): extract payer key derivation helpersby Vincenzo Palazzo · 2bd9266a · Jul 6, 2026 · 2 filesMessage 85 · StrongInformational 17Details
Commit message · Vincenzo Palazzo

refactor(offers): extract payer key derivation helpers

Move the invoice/refund payer key derivation logic into reusable helpers so
payer proofs can derive the same signing keys without duplicating the metadata
and signer flow.

85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope✓ Provides detailed explanatory context
Why it was queued
secret or key materialsigning boundarysigning or wallet path
AI analysis · Informational 17/100

This commit is a code cleanup (refactor) in the Lightning Dev Kit library. It moves existing payer key-derivation logic into shared helper functions so that future 'payer proof' features can reuse the same code. The change does not appear to fix a security bug; it reorganizes existing logic and adds a new public method to re-derive a payer's signing keys from invoice data. No vulnerability or exploit is described in the commit itself.

Lower-priorityoffers: add merkle selective-disclosure primitivesby Vincenzo Palazzo · da6e0bb5 · Jul 6, 2026 · 3 filesMessage 73 · AdequateLow 25Details
Commit message · Vincenzo Palazzo

offers: add merkle selective-disclosure primitives

Extend the BOLT 12 merkle module with selective-disclosure support: build
the full merkle tree from a TLV stream, compute the omitted-TLV markers and
the minimal set of missing hashes for omitted subtrees, and reconstruct the
merkle root from a partial disclosure. These are the primitives a payer proof
is built on.

Co-Authored-By: Rusty Russell <rusty@rustcorp.com.au>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

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

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Low 25/100

This commit adds new code to support BOLT 12 "selective disclosure" payer proofs in the Lightning Dev Kit. It lets someone prove they have a valid signed invoice without revealing every field. The change is a feature addition, not a fix for a known bug, and the commit message and diff do not describe any security vulnerability. However, cryptographic merkle-tree code like this is security-critical because any mistake in how hashes are combined or how omitted fields are reconstructed could let an attacker forge a proof or hide data. The patch includes tests and validation, but because it is brand-new, complex code, it deserves careful review.

Lower-priorityoffers: add BOLT 12 payer proof primitivesby Vincenzo Palazzo · 5747866a · Jul 6, 2026 · 6 filesMessage 86 · StrongLow 32Details
Commit message · Vincenzo Palazzo

offers: add BOLT 12 payer proof primitives

Add the `payer_proof` module: `PayerProof`/`UnsignedPayerProof`, the
`PayerProofBuilder` (with selective disclosure and a derived-key path), bech32
`lnp` encoding, and parse-time verification, implementing the payer proof
extension to BOLT 12 (https://github.com/lightning/bolts/pull/1295). Also
exposes the offer/invoice TLV-type constants and an invoice-bytes accessor used
to build proofs, and a `Sha256` `Writeable`/`Readable` impl for the proof hashes.

Co-Authored-By: Rusty Russell <rusty@rustcorp.com.au>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

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

86/100 · StrongMessage clarity
✓ 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
defensive validation
AI analysis · Low 32/100

This commit adds a new feature to rust-lightning called BOLT 12 payer proofs. It lets someone who paid a BOLT 12 invoice cryptographically prove they paid it, while optionally hiding some invoice details. The change is a large new module plus small supporting changes in invoice, offer, nonce, and serialization code. There is no indication this is a security patch or fixes a vulnerability; it is a new protocol feature implementation with extensive tests and spec test vectors.

Security candidateUpload new fuzz corpus entries as a short-lived CI artifactby Matt Corallo · b9f55b6c · Jul 5, 2026 · 1 fileMessage 83 · StrongInformational 15Details
Commit message · Matt Corallo

Upload new fuzz corpus entries as a short-lived CI artifact

Fork-PR runs get no credentials from Forgejo — neither secrets nor
authorized-integration identity tokens — so the fuzz job cannot push
new corpus entries to the corpus repo from CI. Instead, clone the
corpus from this Forgejo instance (rather than the GitHub copy, so
new entries are detected against the repo they will land in), stage
the new entries plus any SIG* crashes like the GitHub workflow does,
and upload them as an `hfuzz-corpus` artifact with a two-day
retention. The ldk-fuzzing-corpus repo's nightly job sweeps these
artifacts into a corpus pull request and deletes them once processed.

Unlike the GitHub workflow's version, the crash-staging loop here uses
the `rust-lightning/<target>` prefix the corpus entries are actually
staged under (upstream checks the wrong path, so no crash file is ever
picked up there), and it stages crashes for targets that produced no
new corpus entries rather than only creating the target directory as a
side effect of staging corpus files.

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

83/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidencecredential or privilege state
AI analysis · Informational 15/100

This commit changes a CI workflow for the rust-lightning project. It stops trying to push new fuzz test inputs directly to a corpus repository from automated test runs, and instead uploads them as a temporary artifact that a separate scheduled job later collects. This is a workflow reliability and credential-handling improvement, not a security fix or vulnerability.

Lower-priorityAdd upgrade test for legacy post-close monitor update persistenceby GideonBature · 19741bf2 · Jul 5, 2026 · 1 fileMessage 60 · AdequateInformational 17Details
Commit message · GideonBature

Add upgrade test for legacy post-close monitor update persistence

60/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Mentions testing or verification! No meaningful explanatory body
AI analysis · Informational 17/100

This commit only adds a new regression test. It does not change any production code. The test verifies that modern LDK can still read and write very old (pre-0.1) channel monitor update records that used a special sentinel value (u64::MAX) for updates after a channel was closed. There is no vulnerability being fixed here; it is defensive test coverage for an already-handled legacy data format.

AI review queuedci: don't double-assign reviewers, support manual assignment runsby Matt Corallo · 24651a1a · Jul 3, 2026 · 1 fileMessage 90 · StrongInformational 15Details
Commit message · Matt Corallo

ci: don't double-assign reviewers, support manual assignment runs

The assign-reviewer workflow blindly picked a random reviewer every
time it ran, so a re-run (or any future non-opened trigger) could
request review from a second person even when someone was already on
the PR. Teach it to inspect the PR state first:

* Anyone already requested as a reviewer or who has submitted a
review is never picked. The author self-reviewing (commenting on
their own PR) doesn't count.
* On automatic runs (including re-runs), skip assignment entirely if
anyone from the REVIEWERS pool has already reviewed or been
requested; reviews from people outside the pool are ignored.

Also add a workflow_dispatch trigger taking a PR number so a reviewer
can be assigned manually. Manual runs skip the "someone is already on
it" check and always add a new (not-yet-involved) reviewer if an
eligible candidate remains.

This should let us fully emulate the old bot's second-reviewer
assignment logic fully via the action. A first reviewer can go hunt in
the actions page and trigger a second assignment (but we'll add a UI
element in the PR page above merge to trigger this in a nice UI).

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

90/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope✓ Provides detailed explanatory context✓ Names security-relevant behavior explicitly
Why it was queued
signing or wallet pathsecond-pass: security-sensitive path
AI analysis · Informational 15/100

This is a routine update to the project's automated reviewer-assignment workflow. It prevents the bot from accidentally adding a second random reviewer when one is already assigned, and adds a manual trigger so maintainers can request an additional reviewer on demand. There is no security-relevant change here.

AI review queuedFix assign-reviewer's auth by setting the authorized integration audienceby Matt Corallo · 055d334d · Jul 3, 2026 · 1 fileMessage 55 · ThinInformational 18Details
Commit message · Matt Corallo

Fix assign-reviewer's auth by setting the authorized integration audience

55/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Names security-relevant behavior explicitly! No meaningful explanatory body
Why it was queued
signing or wallet pathsecond-pass: security-sensitive path
AI analysis · Informational 18/100

This is a one-line fix to a Forgejo workflow that assigns reviewers. The workflow requests a temporary identity token from the CI system so it can call another service. The change adds an explicit audience parameter to that token request, ensuring the token is only valid for the intended recipient. Without this, the token might be accepted by a broader set of services or rejected by the intended one, depending on how the CI and target service are configured. It is a hardening/configuration fix rather than a user-facing vulnerability in the Lightning library itself.

Lower-priorityfuzz: factor chanmon broadcast relay helperby Joost Jager · 48b2db75 · Jul 3, 2026 · 1 fileMessage 78 · AdequateInformational 15Details
Commit message · Joost Jager

fuzz: factor chanmon broadcast relay helper

Extract the all-node broadcaster drain into a helper and use it
from the finish-time mempool cleanup loop. This leaves relay behavior
unchanged while giving cleanup paths a shared relay primitive.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Informational 15/100

This is a minor code cleanup inside a fuzzing test harness. It extracts a small loop that collects broadcast transactions from all simulated nodes into a new helper function, then calls that helper from an existing cleanup loop. The actual behavior is unchanged; only duplicated code is removed.

Lower-priorityfuzz: sync reloaded monitors from their own best blockby Joost Jager · 3d9a10d2 · Jul 3, 2026 · 1 fileMessage 83 · StrongLow 26Details
Commit message · Joost Jager

fuzz: sync reloaded monitors from their own best block

A node's channel monitors can be persisted at different heights, so on
reload they are not all at the same chain tip. Driving them to the tip
through the shared ChainMonitor from the oldest monitor's height replays
blocks that monitors already ahead have seen, which they interpret as a
reorg. That reorg discards force-close claims registered at a later
height, leaving the closed channel with no transaction to broadcast.

Sync each monitor to the tip from its own best block instead, and sync
the manager separately, matching LDK's per-listener startup contract.

83/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Low 26/100

This commit fixes a bug in LDK's internal fuzz testing harness (not production code). When the test reloaded saved channel data, it incorrectly synchronized all channel monitors from the oldest monitor's block height. Monitors that were already ahead got blocks replayed, which they interpreted as a blockchain reorganization. That fake reorg could discard already-registered force-close transactions, leaving a closed channel with nothing to broadcast. The fix makes each monitor catch up from its own saved height, matching how LDK expects real callers to do startup sync.

Lower-priorityfuzz: settle chanmon force-closes on chainby Joost Jager · 05abdc5a · Jul 3, 2026 · 1 fileMessage 78 · AdequateInformational 14Details
Commit message · Joost Jager

fuzz: settle chanmon force-closes on chain

Route BumpTransaction events through the wallet-backed handler and
drain raw ChainMonitor events during normal event processing. This
matches the background processor path and lets anchor commitments and
claim transactions enter the harness mempool from fuzz opcodes as well
as final cleanup.

During settle_all, alternate event processing, relay, and mining until
tracked force-closed channels no longer report claimable balances. The
bounded loop catches stuck on-chain cleanup instead of leaving
broadcasts or claims unresolved.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Informational 14/100

This commit changes only a fuzzing test harness (chanmon_consistency.rs). It improves how simulated force-closed channels are settled on the fake blockchain during fuzz tests, so the test can catch stuck cleanup states. There is no change to production code, no user-facing behavior change, and no indication of a real-world security vulnerability being fixed.