bitcoin-dev

Combined summary - OP_Expire mempool behavior

Combined summary - OP_Expire mempool behavior

The discussion surrounding Lightning Network (LN) transactions, specifically second-stage transactions such as HTLC-preimage and HTLC-timeout, brings to light the challenges associated with bandwidth consumption when a HTLC-preimage is broadcast close to its expiration.

This situation forces routing nodes to automatically broadcast an HTLC-timeout transaction, potentially leading to a waste of bandwidth for transactions with low chances of being mined. The introduction of altruistic rebroadcasting aims to address this by prioritizing transactions with higher mining probabilities, in line with Replacement-By-Fee (RBF) principles. An in-depth examination on this topic is available through a mailing list thread.

The discourse also touches upon the consistency observed in minimum fees across different nodes, highlighting a uniform fee structure that contrasts with the variance seen in mempool sizes. This predictability is crucial for strategies against divergent mempool fees, as discussed in a GitHub pull request 28488. However, BIP125's rule 4 presents a loophole in nVersion=3 transactions, allowing attackers to perform replacement cycling attacks without adequately covering bandwidth costs. This tactic enables an attacker to exploit the system by using the same Unspent Transaction Outputs (UTXOs) across multiple nodes, thus avoiding fair fee payments.

Further, traditional LN nodes face practical implementation challenges due to their singular tx-relay edge access to the tx-relay network. This limitation complicates the execution of replacement cycling attacks, yet the possibility of an attacker isolating victim transactions within local mempools remains a concern. Despite assumptions that altruistic rebroadcasting would mitigate such attacks, it poses only a minor obstacle given the low cost of acquiring UTXOs.

Additionally, concerns have been raised regarding OP_Expire's potential as a "bandwidth-wasting vector." Although it requires attackers to pay actual fees, thereby making the attack costly, it resembles Replace-By-Fee (RBF) mechanisms where transactions can be replaced for a nominal additional fee. OP_Expire operates under similar principles, suggesting that while it introduces new dynamics in transaction handling, it does not fundamentally alter the economic incentives or costs related to transaction replacements and bandwidth usage. For more insights into these discussions, including contributions from individuals like Peter Todd, readers are encouraged to explore petertodd.org.

Discussion History

0
Peter ToddOriginal Post
March 13, 2024 03:32 UTC
1
March 16, 2024 18:21 UTC
2
March 19, 2024 15:04 UTC