Skip to content

Add bLIP-74: out of band payloads attached to payments over blinded paths - #76

Open
ZZiigguurraatt wants to merge 1 commit into
lightning:masterfrom
ZZiigguurraatt:out_of_band_payloads
Open

ZZiigguurraatt wants to merge 1 commit into
lightning:masterfrom
ZZiigguurraatt:out_of_band_payloads

Conversation

@ZZiigguurraatt

Copy link
Copy Markdown

bLIP-74 attaches an opaque, optional out of band payload to a payment by sending it on a standalone onion message while the HTLC stays plain (no custom records), so it is valid over a BOLT 4 blinded path. The payment is coordinated by a BOLT 11 invoice, either one-time (hash-bearing) or reusable (hash-less).

How it works:

  • The message is paired to the HTLC by payment_hash (or SHA256(preimage) when the sender chose it); the HTLC is tied back to its invoice by the path_id in the blinded path.
  • The receiver holds settlement until it has both the HTLC and the message, so settlement signals delivery. With a sender-chosen preimage it cannot settle without the message, which also makes a reusable hash-less invoice possible.
  • The receiver emits nothing before payment, so it cannot be used as a reflector.

Advantages:

  • Carries an arbitrary and larger payload: a separate onion message, up to the larger BOLT 4 size, not data squeezed into the HTLC onion.
  • Enriches an ordinary blinded invoice payment with sender data (a comment, an order/reference ID, or a higher-level protocol's first message) that keysend cannot deliver over a blinded path.
  • Extends BOLT 11 into a reusable, offer-like endpoint: a hash-less invoice payable any number of times with a sender-chosen preimage, i.e. offer semantics in the ubiquitous BOLT 11 container with no BOLT 12 dependency.
  • No BOLT consensus change: the HTLC stays plain and the data rides existing onion messages, so forwarding nodes are untouched.
  • Reuses existing primitives (plain HTLCs, onion messages, hold invoices) instead of a new offers/invoice system.
  • Needs no always-online static-invoice server (unlike BOLT 12 async payments) and no web server (unlike LNURL).
  • Completes a reusable-endpoint payment with no pre-payment invoice fetch, so lower latency than a BOLT 12 offer.
  • Emits nothing before payment from any party, so it is reflection-safe even against BOLT 12 async payments, whose static-invoice server still reflects.

Registers the reserved values in bLIP-2 — feature bits 264/265 (oob_payment_payloads) and 266/267 (oob_reusable), and onion-message TLV 65552 (oob_payment_message) — and adds the README index row.

…aths

bLIP-74 attaches an opaque, optional out of band payload to a payment by sending it on a standalone onion message while the HTLC stays plain (no custom records), so it is valid over a BOLT 4 blinded path. The payment is coordinated by a BOLT 11 invoice, either one-time (hash-bearing) or reusable (hash-less).

How it works:

- The message is paired to the HTLC by payment_hash (or SHA256(preimage) when the sender chose it); the HTLC is tied back to its invoice by the path_id in the blinded path.
- The receiver holds settlement until it has both the HTLC and the message, so settlement signals delivery. With a sender-chosen preimage it cannot settle without the message, which also makes a reusable hash-less invoice possible.
- The receiver emits nothing before payment, so it cannot be used as a reflector.

Advantages:

- Carries an arbitrary and larger payload: a separate onion message, up to the larger BOLT 4 size, not data squeezed into the HTLC onion.
- Enriches an ordinary blinded invoice payment with sender data (a comment, an order/reference ID, or a higher-level protocol's first message) that keysend cannot deliver over a blinded path.
- Extends BOLT 11 into a reusable, offer-like endpoint: a hash-less invoice payable any number of times with a sender-chosen preimage, i.e. offer semantics in the ubiquitous BOLT 11 container with no BOLT 12 dependency.
- No BOLT consensus change: the HTLC stays plain and the data rides existing onion messages, so forwarding nodes are untouched.
- Reuses existing primitives (plain HTLCs, onion messages, hold invoices) instead of a new offers/invoice system.
- Needs no always-online static-invoice server (unlike BOLT 12 async payments) and no web server (unlike LNURL).
- Completes a reusable-endpoint payment with no pre-payment invoice fetch, so lower latency than a BOLT 12 offer.
- Emits nothing before payment from any party, so it is reflection-safe even against BOLT 12 async payments, whose static-invoice server still reflects.

Registers the reserved values in bLIP-2 — feature bits 264/265 (oob_payment_payloads) and 266/267 (oob_reusable), and onion-message TLV 65552 (oob_payment_message) — and adds the README index row.
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.

1 participant