Skip to content

xpay treatment of onion errors is incomplete #9738

Open

Description

@Lagrang3

It was mentioned in #9681
that disabling a node that returns INVALID_ONION_VERSION, INVALID_ONION_KEY and INVALID_ONION_HMAC
is the correct approach under the assumption that the erring node has a problem.
But it might well be that the previous node is the one providing the invalid onion to its peer.

A more thoughtful response could be to record the pair of nodes (A, B), where B is the one reporting and A is it's ancestor,
then disable all channels connecting A->B, and try again. If we see again node B failing with those errors but for a different
ancestor A', it is likely that B has an issue. Otherwise if we see another node B' having those errors with the same ancestor A
then it is likely that A has an issue.

Also the default behavior in xpay is to disable a channel between nodes (A,B) when a weird error is reported. We might as well
disable every other parallel channel, since the same error is likely to persist between this pair.

Activity

  1. self-assigned this
    on Nov 16, 2026
  2. added this to the v27.03 milestone on Nov 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions