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

invoices: refine update handling

Public commit record

What the developer wrote

Authored by ziggie

35/100 · Opaque
invoices: refine update handling
✓ Descriptive subject! No meaningful explanatory body! Opaque security-relevant change
The short version

What changed, and why it matters

This commit tightens how LND handles invoice payment updates, especially for newer 'AMP' invoices and old-style 'keysend' payments. It adds checks so that the wrong kind of payment cannot be processed against the wrong kind of invoice, and it verifies that stored payment secrets actually match the expected hash. The changes are defensive: they reject mismatched or malformed payments instead of allowing them to proceed. The commit does not say it fixes a known exploit, but the new checks close paths where a payment might have been accepted incorrectly.

Recommended action

Treat this as a hardening patch with possible security relevance. Review whether prior versions could accept a mismatched AMP HTLC replay, process an AMP invoice without MPP, or accept an invalid keysend preimage. If any of those paths were reachable in production, consider a security advisory and backport.

Security signals we found

01

Added preimage/hash mismatch checks for both regular and AMP invoice replays

02

AMP records now require an MPP payload, preventing AMP processing on the legacy path

03

Legacy path now rejects AMP invoices and invoices missing invoice-level preimages

04

Keysend preimages are now validated against the payment hash instead of accepted blindly

05

New unit tests cover mismatch, missing preimage, and keysend validation cases

Risk score

Why this scored 59/100

Our methodology →
Potential impact 18/30
Exploitability 12/25
Stealth signal 8/15
Affected reach 10/15
Confidence 7/10
Evidence quality 4/5
Human-validated context

Community notes

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

No validated notes yet.

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