From 9f57c8ee01df1be37c375e548099e4de743dd11a Mon Sep 17 00:00:00 2001 From: Slyghtning Date: Wed, 8 Oct 2025 09:41:58 +0200 Subject: [PATCH] loopin: add loop-in constants to filter expired deposits --- staticaddr/loopin/interface.go | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/staticaddr/loopin/interface.go b/staticaddr/loopin/interface.go index c4582730..1bf32235 100644 --- a/staticaddr/loopin/interface.go +++ b/staticaddr/loopin/interface.go @@ -15,6 +15,17 @@ import ( "github.com/lightningnetwork/lnd/zpay32" ) +const ( + // DefaultLoopInOnChainCltvDelta is the time lock relative to current + // block height that swap server will accept on the swap initiation + // call. + DefaultLoopInOnChainCltvDelta = 1000 + + // DepositHtlcDelta is a safety buffer of blocks that needs to exist + // between the deposit expiry height and the htlc expiry height. + DepositHtlcDelta = 50 +) + type ( // ValidateLoopInContract validates the contract parameters against our // request.