lightning-dev

CheckTemplateVerify Does Not Scale Due to UTXO's Required For Fee Payment

CheckTemplateVerify Does Not Scale Due to UTXO's Required For Fee Payment

Original Postby ZmnSCPxj

Posted on: January 30, 2024 04:12 UTC

In the realm of Lightning Network protocols, both the current Poon-Dryja model and the anticipated future Decker-Russell-Osuntokun framework encounter a significant issue with fee rates.

Each commitment transaction is bound to a predetermined fee rate which becomes problematic when market rates diverge significantly from this fixed rate, especially if one of the parties is offline for an extended period.

The concept of 'justice' transactions allows for Replace-by-Fee (RBF) in cases of uncooperative channel closures, as implemented by CLN's aggressive RBF policy. However, this does not address the fundamental problem tied to commitment transactions. The proposed solution of anchor commitments involves adding an extra output that enables Child-Pays-For-Parent (CPFP) transactions, at the cost of increased block space usage due to the additional outputs.

Peter Todd has suggested signing multiple off-chain transaction versions with varying fee rates to counteract the rigidity of single-rate commitments. This approach, however, presents an imbalance where parties not responsible for on-chain fees may prefer using the highest-feerate version, thus increasing storage costs for the other party without any drawback for themselves. Additionally, the disincentive for the fee-paying party to provide signatures for high-fee transactions could lead to a situation where anchor outputs are still required to adjust the fee.

This strategy might be feasible if both parties were equally responsible for on-chain fees, necessitating mutual contributions to channel opens and avoiding unilateral funding. The fairness of such an arrangement would have to be defined, perhaps by equal fees or fees proportional to the amount held within the channel. This system could potentially support multiple fee-rate transactions, yet complications could arise concerning the management of HTLCs within these larger contracts. Specifically, whether HTLC resolutions require separate transactions and if they need to be included in the multi-fee-rate structure, potentially leading to a quadratic increase in the number of necessary transactions based on the number of fee rates considered.