Skip to content

Commit

Permalink
Increase maximum cltv_expiry_delta (#635)
Browse files Browse the repository at this point in the history
We allow `cltv_expiry_delta` up to two weeks, to align with other
implementations. This allows using a larger trampoline expiry delta,
which will reduce the frequency of force-closed channels because a
wallet doesn't come back online in time to settle one of their HTLCs.
  • Loading branch information
t-bast authored May 3, 2024
1 parent 5547972 commit cce4df3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -665,7 +665,7 @@ object Channel {

// this is defined in BOLT 11
val MIN_CLTV_EXPIRY_DELTA = CltvExpiryDelta(18)
val MAX_CLTV_EXPIRY_DELTA = CltvExpiryDelta(7 * 144) // one week
val MAX_CLTV_EXPIRY_DELTA = CltvExpiryDelta(2 * 7 * 144) // two weeks

// since BOLT 1.1, there is a max value for the refund delay of the main commitment tx
val MAX_TO_SELF_DELAY = CltvExpiryDelta(2016)
Expand Down

0 comments on commit cce4df3

Please sign in to comment.