lightning-terminal/rules/docs
Elle Mouton f8a36010e2
rules: add on-chain budget
This adds an on-chain budget that handles requests and responses for the
following endpoints:

* OpenChannelSync
* BatchOpenChannel

The budget rule checks that the onchain fee rate is not violated and
that pending and confirmed amounts are handled correctly.

An edge case can occur when lit crashes or shuts down after the budget
rule has forwarded a request but didn't receive a response yet. The
pending budget is not removed in case the request didn't go through and
is not accounted towards the spent budget in case the request did go
through. To be able to handle these cases in the future we add a unique
identifier to the request, that can be checked by calling LND's channel
bookkeeping APIs. Not all of them expose the identifier yet, which is
why pending actions cannot be deleted yet. This leads to underspending
of the budget and can be fixed by user intervention by creating a new
session. The memo prefix is removed when reading forwarding the
bookkeeping requests for privacy reasons.
2024-07-02 18:21:41 +02:00
..
onchain_budget.md rules: add on-chain budget 2024-07-02 18:21:41 +02:00