Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore legacy onion (damn you lnd!) #7352

Conversation

rustyrussell
Copy link
Contributor

Let's remove it again in... um...

Shit, it's going to be there forever, isn't it?

😭

Fixes: #7347

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This fails, because l2 can't decode the onion:

```
lightningd-2 2024-05-28T21:43:35.137Z DEBUG   0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-chan#1: Rejecting their htlc 0 since onion is unprocessable WIRE_INVALID_ONION_HMAC ss=4202c24ea44d9029a2ea3abb24cded51da93164f8bb5cddce9cc824af9945435
```

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
We do this by literally creating the modern-style TLV, and pretending we found it in the onion.

This isolates us from messing with any callers, who don't even know.

Co-programmed-with: Alex Myers <alex@endothermic.dev>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Fixes: ElementsProject#7347
Changelog-Fixed: Protocol: forward legacy non-TLV onions which we removed in 22.11 and spec itself in Feb 2022.  Still sent by LND nodes who haven't seen our node_announcement.
@rustyrussell rustyrussell added this to the v24.05 milestone May 29, 2024
Copy link
Collaborator

@vincenzopalazzo vincenzopalazzo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was going to preferer some git revert commit in this way we can revert the revert operation at some point :P

Shit, it's going to be there forever, isn't it?

If we remove it, what will we pass down to future generations? 😹

ACK e0d8735

Copy link
Member

@cdecker cdecker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good, too bad they haven't removed the legacy version yet.

ACK e0d8735

lightningd/pay.c Show resolved Hide resolved
Copy link
Collaborator

@endothermicdev endothermicdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK e0d8735

@endothermicdev endothermicdev merged commit 818cf06 into ElementsProject:master May 29, 2024
39 checks passed
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.

Interop: INVALID_ONION_HMAC
4 participants