Skip to content

Commit 29e4c3f

Browse files
21M4TWrustyrussell
authored andcommitted
offers: require opt_onion_message for incoming invoices too.
Changelog-Fixed: offers: require peers for blinded paths to have `option_onion_messages`, due to reports of LND not forwarding our blinded payments correctly.
1 parent a3441ff commit 29e4c3f

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

plugins/offers_invreq_hook.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,12 @@ static struct command_result *add_blindedpaths(struct command *cmd,
381381
if (!we_want_blinded_path(cmd->plugin, true))
382382
return create_invoicereq(cmd, ir);
383383

384-
return find_best_peer(cmd, 1ULL << OPT_ROUTE_BLINDING,
384+
/* Technically, this only needs OPT_ROUTE_BLINDING, but we have a report
385+
* of this failing with LND nodes, so we require both OPT_ROUTE_BLINDING
386+
* *and* OPT_ONION_MESSAGES. This also helps support nodes which provide
387+
* us onion messaging. */
388+
return find_best_peer(cmd,
389+
(1ULL << OPT_ROUTE_BLINDING) | (1ULL << OPT_ONION_MESSAGES),
385390
found_best_peer, ir);
386391
}
387392

0 commit comments

Comments
 (0)