lightningd: new option for htlc dust limit

To reduce the surface area of amount of a channel balance that can be
eaten up as htlc dust, we introduce a new config
'--max-dust-htlc-exposure-msat', which sets the max amount that any
channel's balance can be added as dust

Changelog-Added: config: new option --max-dust-htlc-exposure-msat, which limits the total amount of sats to be allowed as dust on a channel
This commit is contained in:
niftynei
2021-09-28 14:03:08 -05:00
committed by Christian Decker
parent 0f0a77e322
commit 1fe829c546
13 changed files with 62 additions and 5 deletions

View File

@@ -149,6 +149,7 @@ static int parse_config(char *argv[],
config->max_htlc_value_in_flight = AMOUNT_MSAT(-1ULL);
config->htlc_minimum = AMOUNT_MSAT(0);
config->max_accepted_htlcs = 483;
config->max_dust_htlc_exposure_msat = AMOUNT_MSAT(-1ULL);
config->to_self_delay = atoi(argv[argnum]);
argnum++;