1
0
Fork 0
mirror of https://github.com/ACINQ/eclair.git synced 2025-02-22 22:25:26 +01:00
eclair/eclair-core
Bastien Teinturier 304290d841
Various refactoring for trampoline blinded paths (#2952)
* Fix offer description documentation

And remove the `currency` fields as we have no short-term plans to
support currency conversion in `eclair`.

* Relax `payment_constraints` requirement in final blinded payload

We don't always need to include a `payment_constraints` field for
ourselves: it's fine to accept payment that don't contain one as
long as we created the `encrypted_recipient_data`, which we can
verify using the `path_id`. We were too restrictive for no good
reason.

* Allow omitting `total_amount` in blinded payments

If the `total_amount` field isn't provided, we can safely default to
using the `amount`, which saves space in the onion. Note that we keep
always encoding it in the outgoing payments we send, we're simply more
permissive when receiving payments.

* Refactor `decryptEncryptedRecipientData`

We extract a helper method for decrypting encrypted recipient data
which will be used when decrypting trampoline blinded paths.

* Use relay methods in `PaymentOnion.IntermediatePayload.NodeRelay`

In order to support blinded trampoline payments, we won't have access to
a direct `amount_to_forward` field, but will use a `payment_relay` TLV
instead, which only allows calculating the outgoing amount from the
incoming amount (same thing for the expiry).

We refactor this to simplify the diff when introducing blinded trampoline
payments.
2024-11-29 17:08:58 +01:00
..
src Various refactoring for trampoline blinded paths (#2952) 2024-11-29 17:08:58 +01:00
eclair-cli Automatically disable from_future_htlc when abused (#2928) 2024-10-15 11:18:33 +02:00
pom.xml Update Bitcoin Core to 27.2 (#2940) 2024-11-20 15:51:25 +01:00