bitcoin-dev

Libre Relay v27.1 released with lower 1.25x replacement threshold

Libre Relay v27.1 released with lower 1.25x replacement threshold

Original Postby Peter Todd

Posted on: June 20, 2024 16:33 UTC

In a recent update to the Libre Relay project hosted on GitHub, significant changes have been made to the replace-by-fee-rate (RBFR) mechanism.

The threshold for replacing transactions based on fee rate has been adjusted to 1.25 times the original fee rate from the previous factor of 2. This adjustment aims to mitigate the challenges associated with transaction pinning by both reducing the maximum cost required to counteract pinning and simultaneously increasing the expected costs for attempting such pinning. These modifications are designed to enhance the efficiency of transaction processing within the network by ensuring that transactions with slightly higher fee rates can more easily replace those with lower fees, thereby discouraging unnecessary transaction pinning.

The developer behind these changes, Peter Todd, suggests that this is an opportune moment for critics of the RBFR proposal to demonstrate any significant flaws, particularly those that could lead to denial of service (DoS) attacks that surpass the effectiveness of existing relay attacks that occur in the absence of RBFR mechanisms. He highlights practical instances where the modified RBFR system has already proven beneficial in real-world scenarios, particularly within the context of the Lightning Network. Specifically, there have been cases where Lightning Network Daemon (LND) nodes encountered issues with anchor outputs being spent after the 16 block CheckSequenceVerify (CSV) timeout by third parties. This led to situations where conflicting transactions with higher fees, created by LND nodes, were initially unable to be mined due to the original transactions' higher absolute fees. However, with the implementation of the updated RBFR and the propagation through Libre Relay nodes, such transactions eventually got mined, suggesting a potential improvement in handling similar complications.

Furthermore, Todd's experience with F2Pool mining a higher fee-rate transaction, which conflicted with another transaction and was not recognized by an LND node until later, underscores the practical benefits of using Libre Relay, especially for operators of Lightning nodes. The observed behavior from F2Pool, which might be attributed to its shorter mempool expiration time, points towards the necessity for Lightning node operators to consider employing Libre Relay to address vulnerabilities related to transaction pinning within the Lightning protocol framework.

For more detailed insights into the RBFR proposal and related discussions, references are provided to further information at Peter Todd's website, along with a discourse on potential deficiencies of the RBFR proposal available at this link, and ongoing discussions within the Bitcoin development community at BitcoinDev Google Group and another thread here.