ACINQ / eclair

A scala implementation of the Lightning Network.
Apache License 2.0
1.23k stars 267 forks source link

Variable size for trampoline onion #2810

Closed thomash-acinq closed 8 months ago

thomash-acinq commented 8 months ago

The size of trampoline onions was fixed at 400 bytes. We remove this limit, allowing larger trampoline onions when necessary. For backward compatibility, anything that used to fit in a 400 bytes onion still uses a 400 bytes onion (even if it could fit in less). Payments with large metadata that would fail because of the 400 bytes limit are now possible and the onion uses exactly the size that's needed, nothing more, nothing less. The size of the trampoline onion is still constrained by the size of the standard onion (1300 bytes).