Skip to content

Commit 5ca6ffa

Browse files
Don't avoid retrying a blinded path if failure came from the wrong node.
Without this check, a forwarding node not on the blinded path could error with INVALID_ONION_BLINDING and cause us to unnecessarily ban a blinded path from future payment retries.
1 parent ab5355a commit 5ca6ffa

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lightning/src/ln/outbound_payment.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1653,7 +1653,9 @@ impl OutboundPayments {
16531653
// next-hop is needlessly blaming us!
16541654
payment.get_mut().insert_previously_failed_scid(scid);
16551655
}
1656-
if onion_error_code == Some(INVALID_ONION_BLINDING) {
1656+
if onion_error_code == Some(INVALID_ONION_BLINDING) &&
1657+
node_id == path.hops.last().map(|h| h.pubkey)
1658+
{
16571659
debug_assert!(short_channel_id.is_none());
16581660
if let Some(bt) = &path.blinded_tail {
16591661
payment.get_mut().insert_previously_failed_blinded_path(&bt);

0 commit comments

Comments
 (0)