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

Add amounts to HTLC locators

Public commit record

What the developer wrote

Authored by benthecarman

68/100 · Adequate
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
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

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.

Recommended action

No security action required. Treat as a normal feature commit. Reviewers may want to confirm that the legacy deserialization fallback for prev_htlcs amount_msat (using outbound_amount_forwarded_msat + total fee when total_fee_earned_msat is known) is acceptable for downstream accounting, but this is a data-quality consideration, not a security issue.

Security signals we found

01

No memory-safety issues introduced (Rust, optional u64 field)

02

No new panics, unwraps, or arithmetic on untrusted values beyond existing fee math

03

Serialization uses existing TLV framework with optional fields, preserving backward compatibility

04

No authentication, authorization, or cryptographic changes

05

No external input parsing beyond existing event deserialization

Risk score

Why this scored 19/100

Our methodology →
Potential impact 2/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 3/15
Confidence 9/10
Evidence quality 5/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.