Skip to content

Commit

Permalink
More tweaks from jkczyz.
Browse files Browse the repository at this point in the history
Signed-off-by: Rusty Russell <[email protected]>

iff --git a/12-offer-encoding.md b/12-offer-encoding.md
index 8671024..1459098 100644
  • Loading branch information
rustyrussell committed Jan 9, 2023
1 parent 363d9a5 commit 18912bc
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions 12-offer-encoding.md
Original file line number Diff line number Diff line change
Expand Up @@ -434,9 +434,9 @@ The writer:
- otherwise:
- MUST NOT set `invreq_quantity`
- otherwise (not responding to an offer):
- MUST set (or not set) `offer_metadata`, `offer_description`, `offer_absolute_expiry`, `offer_paths` and `offer_issuer` as it would for an offer.
- MUST set (or not set) `offer_description`, `offer_absolute_expiry`, `offer_paths` and `offer_issuer` as it would for an offer.
- MUST set `invreq_payer_id` as it would set `offer_node_id` for an offer.
- MUST NOT include `signature`, `offer_chains`, `offer_amount`, `offer_currency`, `offer_features`, `offer_quantity_max` or `offer_node_id`
- MUST NOT include `signature`, `offer_metadata`, `offer_chains`, `offer_amount`, `offer_currency`, `offer_features`, `offer_quantity_max` or `offer_node_id`
- if the chain for the invoice is not solely bitcoin:
- MUST specify `invreq_chain` the offer is valid for.
- MUST set `invreq_amount`.
Expand Down Expand Up @@ -644,7 +644,7 @@ may (due to capacity limits on a single channel) require it.

A writer of an invoice:
- MUST set `invoice_created_at` to the number of seconds since Midnight 1
January 1970, UTC when the offer was created.
January 1970, UTC when the invoice was created.
- MUST set `invoice_amount` to the minimum amount it will accept, in units of
the minimal lightning-payable unit (e.g. milli-satoshis for bitcoin) for
`invreq_chain`.
Expand Down Expand Up @@ -712,7 +712,7 @@ A reader of an invoice:
- if the invoice is a response to an `invoice_request`:
- MUST reject the invoice if all fields less than type 160 do not exactly match the `invoice_request`.
- if `offer_node_id` is present (invoice_request for an offer):
- MUST reject the invoice if `invoice_node_id` is not equal to `offer_node_id`.
- MUST reject the invoice if `invoice_node_id` is not equal to `offer_node_id`.
- otherwise (invoice_request without an offer):
- MAY reject the invoice if it cannot confirm that `invoice_node_id` is correct, out-of-band.
- otherwise: (a invoice presented without being requested, eg. scanned by user):
Expand All @@ -723,12 +723,13 @@ A reader of an invoice:
- MUST reject the invoice if `invreq_payer_id` is present.
- MUST reject the invoice if `offer_description` is not present.
- MUST reject the invoice if `signature` is not a valid signature using `invoice_node_id` as described in [Signature Calculation](#signature-calculation).
- SHOULD prefer to use earlier `invoice_paths` over later ones if it has no other reason for preference.
- if `invoice_features` contains the MPP/compulsory bit:
- SHOULD pay the invoice via multiple separate blinded paths.
- MUST pay the invoice via multiple separate blinded paths.
- otherwise, if `invoice_features` contains the MPP/optional bit:
- MAY pay the invoice via multiple separate payments.
- otherwise:
- MUST NOT use multiple payments to pay the invoice.
- MUST NOT use multiple parts to pay the invoice.
- SHOULD confirm authorization if `invoice_amount`.`msat` is not within the amount range authorized.
- for the bitcoin chain, if the invoice specifies `invoice_fallbacks`:
- MUST ignore any `fallback_address` for which `version` is greater than 16.
Expand Down

0 comments on commit 18912bc

Please sign in to comment.