From 655579e2655f0d3ee04a6895b0ae6a64ab3ac7b1 Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Wed, 30 Jun 2021 03:16:01 +0000 Subject: [PATCH] Slightly increase the allowed fee upper limit on remote update_fees At least lnd is fairly aggressively high in their (non-anchor) fee estimation, running the risk of force-closure. Further, because we rely on a fee estimator we don't have full control over, we should not assume our users' fees are particularly conservative, and thus give our peers a lot of leeway. --- lightning/src/ln/channel.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightning/src/ln/channel.rs b/lightning/src/ln/channel.rs index f88dfb317e5..b25567533e7 100644 --- a/lightning/src/ln/channel.rs +++ b/lightning/src/ln/channel.rs @@ -675,7 +675,7 @@ impl Channel { if feerate_per_kw < lower_limit { return Err(ChannelError::Close(format!("Peer's feerate much too low. Actual: {}. Our expected lower limit: {}", feerate_per_kw, lower_limit))); } - let upper_limit = fee_estimator.get_est_sat_per_1000_weight(ConfirmationTarget::HighPriority) as u64 * 2; + let upper_limit = fee_estimator.get_est_sat_per_1000_weight(ConfirmationTarget::HighPriority) as u64 * 4; if feerate_per_kw as u64 > upper_limit { return Err(ChannelError::Close(format!("Peer's feerate much too high. Actual: {}. Our expected upper limit: {}", feerate_per_kw, upper_limit))); }