bitcoin-dev

OP_Expire and Coinbase-Like Behavior: Making HTLCs Safer by Letting Transactions Expire Safely

OP_Expire and Coinbase-Like Behavior: Making HTLCs Safer by Letting Transactions Expire Safely

Original Postby Peter Todd

Posted on: October 23, 2023 15:45 UTC

The email discusses the suggestion of using "nExpiryHeight" instead of time-based expiration in programming.

The sender strongly recommends this approach to avoid any potential issues related to miners manipulating the current time. They also mention that using a time-based approach was a design mistake in the past. Additionally, the sender proposes redefining an opcode and suggests alternative names for it, such as OP_Expire or OP_CheckExpiryTime. The sender acknowledges a previous proposal but mentions that it forgot about the taproot annex, which may require the use of the "nExpiryHeight" field instead. The sender also suggests that having a nExpiryHeight field could be useful in cases where a signature covering the field is enough.