Skip to content

Add support for arbitrary length onion errors#376

Merged
t-bast merged 2 commits intomasterfrom
arbitrary-size-onion-errors
Oct 3, 2022
Merged

Add support for arbitrary length onion errors#376
t-bast merged 2 commits intomasterfrom
arbitrary-size-onion-errors

Conversation

@t-bast
Copy link
Member

@t-bast t-bast commented Sep 29, 2022

The specification recommends using a length of 256 for onion errors, but it doesn't say that we should reject errors that use a different length.

We may want to start creating errors with a bigger length than 256 if we need to transmit more data to the sender. In order to prepare for this, we keep creating 256-bytes onion errors, but allow receiving errors of arbitrary length.

We also remove support for legacy fixed-size onion payloads.

@t-bast t-bast force-pushed the arbitrary-size-onion-errors branch 2 times, most recently from a866417 to 5650ac9 Compare September 30, 2022 14:05
The specification recommends using a length of 256 for onion errors, but
it doesn't say that we should reject errors that use a different length.

We may want to start creating errors with a bigger length than 256 if we
need to transmit more data to the sender. In order to prepare for this,
we keep creating 256-bytes onion errors, but allow receiving errors of
arbitrary length.
This has been removed from the spec recently, see:
lightning/bolts#962
@t-bast t-bast force-pushed the arbitrary-size-onion-errors branch from 5650ac9 to 5059aeb Compare September 30, 2022 15:14
@t-bast t-bast merged commit bc94e12 into master Oct 3, 2022
@t-bast t-bast deleted the arbitrary-size-onion-errors branch October 3, 2022 13:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants