Currently HTLC's timeout transaction relies on absolute timelock enforced on the script. It allows a counterparty to withdraw the money from the contract if the other party doesn't release the preimage. What would have been the problem if instead of using timelock before the counterparty can unlock its money, the condition is replaced with timelock puzzle? The time taken to solve the puzzle will be same as the locktime of the offchain contract.

  • How do you (gu)estimate the "time taken to solve the puzzle" ? – darosior Aug 25 at 11:25
  • That can be decided by the sender who wants to initiate payment – Subhra Mazumdar Aug 25 at 11:37
  • Lightning HTLCs use relative timelock (CSV) not absolute (CLTV). This is because we don't know when the commitment tx will be confirmed (it is offline) – pinhead Aug 25 at 11:43
  • 1
    I was talking about the timeout period of HTLC within which the counterparty must provide the preimage in order to claim payment. Isn't that using an absolute timelock? – Subhra Mazumdar Aug 25 at 12:01
  • sorry you're right - in fact CSV and CLTV are both employed in different LN use cases: github.com/lightningnetwork/lightning-rfc/blob/master/… – pinhead Aug 25 at 12:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.