Rusty Russell [ARCHIVE] on Nostr: 📅 Original date posted:2018-10-17 📝 Original message: Hi all, Everywhere in the ...
📅 Original date posted:2018-10-17
📝 Original message:
Hi all,
Everywhere in the protocol where we negotiate, we've had
problems: what do you do if you can't agree? In most cases, we've
settled on defacto generally-accepted values which aren't mentioned
anywhere in the spec (I've skimmed codebases below, looked at defaults).
I'd like to re-examine these in light of our real-life experience and
see if we can simplify them, or at least make suggestions:
funding_satoshis
----------------
c-lightning: must be >= 1000 (after reserve subtracted)
Eclair: must be >= 100000
lnd: any
SUGGESTION: At 253 satoshi/kSipa, and dust at 546, 1000 is too low to be
sane (one output would always be dust). Eclair seems pessimistic
though; Should we suggest that any channel under 3 x min(our_dust_limit,
their_dust_limit) SHOULD be rejected as too small (ie. min is 546*3).
dust_limit_satoshis
-------------------
c-lightning: gives 546, accepts any.
Eclair: gives 546 (configurable), accepts >= 546.
lnd: gives 573, accepts any.
(Note: eclair's check here is overzealous, but friendly).
SUGGESTION: we have to make this variable in future anyway (IRL it
depends on min_relay_fee, which in turn depends on backlog...).
I'd love to just pick a number :(
max_htlc_value_in_flight_msat
-----------------------------
c-lightning: gives U64_MAX, accepts >= 1000000.
Eclair: gives 5000000000, accepts any.
lnd: gives capacity - reserve, accepts >= 5 * htlc_minimum_msat.
SUGGESTION: maybe drop it (must be U64_MAX?).
channel_reserve_satoshis
------------------------
c-lightning: gives 1% (rounded down), accepts <= capacity - 1000000.
Eclair: gives 1% (?), accepts <= 5% (configurable)
lnd: gives 1%, accepts <= 20%
SUGGESTION: require it be 1% (rounded down).
htlc_minimum_msat
-----------------
c-lightning: gives 0, accepts up to 0.1% of channel capacity.
Eclair: gives 1, accepts any.
lnd: gives 1000, accepts any.
SUGGESTION: maybe drop it (ie. must be 0?)
to_self_delay
-------------
c-lightning: gives 144, accepts <= 2016
Eclair: gives 144, accepts <= 2000
lnd: gives 144-2016 (proportional to funding), accepts <= 10000
SUGGESTION: require it to be <= 2016. Weaker suggestion: make it 2016,
or use lnd's proportional formula.
max_accepted_htlcs
------------------
c-lightning: gives 483, accepts > 0.
Eclair: gives 30, accepts any.
lnd: gives 483, accepts >= 5
SUGGESTION: not sure why Eclair limits. Maybe make it 483?
minimum_depth
-------------
c-lightning: gives 3, accepts <= 10.
Eclair: gives 3, accepts any.
lnd: gives 3-6 (scaling with funding), accepts any.
SUGGESTION: This field is only a suggestion anyway; you can always wait
longer before sending funding_locked. Let's limit it to <= 6?
Are there any other areas of hidden consensus should illuminate and may
simplify?
Thanks!
Rusty.
Published at
2023-06-09 12:51:52Event JSON
{
"id": "dd17ad5be38acda6d0fdfff1b65b34b1071eff824461c8c3057c58fda12e4be9",
"pubkey": "13bd8c1c5e3b3508a07c92598647160b11ab0deef4c452098e223e443c1ca425",
"created_at": 1686315112,
"kind": 1,
"tags": [
[
"e",
"fd99948aab349ef42bd3c03cc68b4a1b7f01657674565bc9f6481caaeee0d1d0",
"",
"reply"
],
[
"p",
"9456f7acb763eaab2e02bd8e60cf17df74f352c2ae579dce1f1dd25c95dd611c"
]
],
"content": "📅 Original date posted:2018-10-17\n📝 Original message:\nHi all,\n\n Everywhere in the protocol where we negotiate, we've had\nproblems: what do you do if you can't agree? In most cases, we've\nsettled on defacto generally-accepted values which aren't mentioned\nanywhere in the spec (I've skimmed codebases below, looked at defaults).\nI'd like to re-examine these in light of our real-life experience and\nsee if we can simplify them, or at least make suggestions:\n\nfunding_satoshis\n----------------\n\nc-lightning: must be \u003e= 1000 (after reserve subtracted)\nEclair: must be \u003e= 100000\nlnd: any\n\nSUGGESTION: At 253 satoshi/kSipa, and dust at 546, 1000 is too low to be\nsane (one output would always be dust). Eclair seems pessimistic\nthough; Should we suggest that any channel under 3 x min(our_dust_limit,\ntheir_dust_limit) SHOULD be rejected as too small (ie. min is 546*3).\n\n\ndust_limit_satoshis\n-------------------\n\nc-lightning: gives 546, accepts any.\nEclair: gives 546 (configurable), accepts \u003e= 546.\nlnd: gives 573, accepts any.\n\n(Note: eclair's check here is overzealous, but friendly).\n\nSUGGESTION: we have to make this variable in future anyway (IRL it\ndepends on min_relay_fee, which in turn depends on backlog...).\nI'd love to just pick a number :(\n\n\nmax_htlc_value_in_flight_msat\n-----------------------------\nc-lightning: gives U64_MAX, accepts \u003e= 1000000.\nEclair: gives 5000000000, accepts any.\nlnd: gives capacity - reserve, accepts \u003e= 5 * htlc_minimum_msat.\n\nSUGGESTION: maybe drop it (must be U64_MAX?).\n\n\nchannel_reserve_satoshis\n------------------------\n\nc-lightning: gives 1% (rounded down), accepts \u003c= capacity - 1000000.\nEclair: gives 1% (?), accepts \u003c= 5% (configurable)\nlnd: gives 1%, accepts \u003c= 20%\n\nSUGGESTION: require it be 1% (rounded down).\n\n\nhtlc_minimum_msat\n-----------------\n\nc-lightning: gives 0, accepts up to 0.1% of channel capacity.\nEclair: gives 1, accepts any.\nlnd: gives 1000, accepts any.\n\nSUGGESTION: maybe drop it (ie. must be 0?)\n\n\nto_self_delay\n-------------\n\nc-lightning: gives 144, accepts \u003c= 2016\nEclair: gives 144, accepts \u003c= 2000\nlnd: gives 144-2016 (proportional to funding), accepts \u003c= 10000\n\nSUGGESTION: require it to be \u003c= 2016. Weaker suggestion: make it 2016,\nor use lnd's proportional formula.\n\n\nmax_accepted_htlcs\n------------------\n\nc-lightning: gives 483, accepts \u003e 0.\nEclair: gives 30, accepts any.\nlnd: gives 483, accepts \u003e= 5\n\nSUGGESTION: not sure why Eclair limits. Maybe make it 483?\n\n\nminimum_depth\n-------------\n\nc-lightning: gives 3, accepts \u003c= 10.\nEclair: gives 3, accepts any.\nlnd: gives 3-6 (scaling with funding), accepts any.\n\nSUGGESTION: This field is only a suggestion anyway; you can always wait\nlonger before sending funding_locked. Let's limit it to \u003c= 6?\n\n\nAre there any other areas of hidden consensus should illuminate and may\nsimplify?\n\nThanks!\nRusty.",
"sig": "2675bb773bb45d49e0769c346285852bfc0310367989697d6681396b8df2072225fcff5067674e5cae3f7c7ecf7a6057aac3b7d56fc2fee9eac91bfff8155e42"
}