executing-plans
executing-plans
Use when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available
lightning-replacement-cyclingReplacement cycling attack on Lightning (Riard 2023): exploits BIP125 rule 5 to indefinitely delay an honest HTLC-timeout, costing the victim. Mitigated by TRUC v3 + ephemeral anchors. USE WHEN: auditing LN security posture, evaluating fee-bumping strategies, understanding why TRUC was activated.
Independent GitHub snapshot · Automated classification · Original documentation governs
Disclosed by Antoine Riard, Oct 2023. A novel mempool-policy attack against Lightning where an attacker repeatedly cycles RBF-replacing their own malicious child tx, forcing your honest fee-bumping attempts to incur progressively higher costs while their tx sits in mempool, eventually causing your legitimate sweep tx (HTLC-timeout) to miss its CLTV deadline.
You're routing a payment Alice → You → Bob:
If Bob force-closes and you can't claim his outgoing HTLC before your incoming HTLC times out → you lose the payment forwarded to Bob but still owe Alice.
Attacker (Bob) attempts:
The ATTACK COST to Bob is small (he keeps replacing his own tx with incremental bumps); the COST TO YOU includes both the failed timeout fees and the lost payment to Alice.
BIP125 rule 5: replacement tx must pay extra incrementalrelayfee × size_increase beyond the original. But this allows an attacker who
controls a competing tx to force you to keep bumping ahead of
them, while their own bumps are tiny.
v3 transactions limit:
This breaks the cycling pattern: attacker can't keep stacking replacements with tiny bumps; sibling eviction lets honest party replace cheaply.
Anchor with value=0 and trivially-spendable script. Must be spent
in the same package as parent. Eliminates pinning surface (anchor
isn't independently spendable).
Pre-sign HTLC-timeout txs with a generous fee. If mempool fee rates spike beyond expectations, you have headroom.
Watchtowers monitor not just for cheating commitments but also for HTLC pinning attempts; can attempt punitive replacement.