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

swaps: cleanup data after swap gets failed

Public commit record

What the developer wrote

Authored by f321x

68/100 · Adequate
swaps: cleanup data after swap gets failed

Removes the persisted payment info from lnworker once a swap got failed.
Stops persisting the OnionRoutingFailure as it is sufficient to delete
the payment info to fail potential incoming htlcs.
Deletes stored swap leftovers in lnworker and SwapManager
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This commit cleans up leftover data after a failed Lightning submarine swap in the Electrum wallet. Previously, failed swaps could leave stale payment information, routing-failure records, and internal index entries behind. The patch removes those leftovers so they cannot accidentally be reused or misinterpreted later. It is a defensive hardening change rather than a fix for a known active attack.

Recommended action

Treat as a routine hardening patch. Users running submarine-swap functionality should update to a version containing this commit. No immediate incident response is indicated by the commit itself, but operators should monitor for any prior anomalous swap behavior.

Security signals we found

01

Removal of persisted payment/routing state for failed swaps

02

Deletion of internal index entries that could reference stale swap objects

03

Defensive cleanup of hold-invoice callbacks and prepay hashes

04

Commit message frames change as cleanup, not as a security bug fix

Risk score

Why this scored 42/100

Our methodology →
Potential impact 12/30
Exploitability 8/25
Stealth signal 6/15
Affected reach 7/15
Confidence 6/10
Evidence quality 3/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.