Yaacov Akiba Slama [ARCHIVE] on Nostr: ๐
Original date posted:2019-11-13 ๐ Original message: On 13/11/2019 05:44, ...
๐
Original date posted:2019-11-13
๐ Original message:
On 13/11/2019 05:44, Rusty Russell wrote:
> Yaacov Akiba Slama <ya at slamail.org> writes:
>> ย Seller: Quotation (UBL)
>>
>> ย Buyer: Order (UBL)
>>
>> ย Seller: Prepayment Invoice (UBL)
>>
>> ย Seller: Invoice (LN)
>>
>> ย Buyer/Seller: Payment & Ack (LN)
>>
>> ย Seller: Receipt (UBL)
>>
>
> This would be UBL treating Lightning as a dumb payment layer, which is a
> little like faxing email, and not a use case I'd be promoting for
> Lightning.
I don't understand the comparison. Both email an fax are way to transmit
data and are not related to the *content* of what is transmitted.
Consequently email and fax are in competing as a way to transmit data.
But LN and UBL (as I understand them) are not in competition because:
* LN is a messaging protocol (soon) and a payment protocol.
* UBL is a protocol defining business interaction workflow *around*
payments.
So we can integrate between them without intermixing the semantics of
the protocols but we need only to define the interaction points between
them.
In the previous worflow, the seller can for instance add in the LN
invoice H(Quotation (UBL)||Order(UBL)||Prepayment Invoice(UBL)), and use
H(Receipt(UBL)) as preimage. With such a workflow, the UBL documents are
cryptographically tied to the LN payment.
So the property of UBL of not being machine *handlable* is not altered
but the LN cryptographic properties are still used to tie the workflow.
Am I missing something?
--yas
>
> To be clear: the full UBL spec is machine *parsable* but definitely not
> designed to be machine *handlable*. This makes sense, since a machine
> cannot generally choose between quotations or interpret general contract
> terms.
>
> However, for the simpler (but very common!) case of an offer->purchase
> flow, we can define a subset of UBL for which this *can* be done, and a
> further-limited subset which must be examined by the user
> (e.g. description of goods, price details, shipping info).
>
> In addition, the atomic nature of LN needs to be baked into the
> protocol; in LN taking the payment *requires* a cryptographic receipt,
> and neutering this property would be horribly short-sighted.
>
> We need to define UBL extensions for the LN fields to tie them all
> together (e.g. payment_hash, node_id). We also need to define a
> transport mechanism for these over the Lightning Network.
>
> This is all quite possible! But it will take time and is a signficant
> amount of work: I need to be sure that others feel the same way before I
> embark on this project.
>
> Cheers,
> Rusty.
>
>>> It's also worth noting that, even compressed, none of the UBL examples
>>> fit into the 1023 byte limit of the existing invoice format:
>>>
>>> UBL-Quotation-2.1-Example.xml: 1864 bytes (gz)
>>> UBL-Order-2.1-Example.xml: 2515 bytes (gz)
>>> UBL-Invoice-2.1-Example.xml: 3163 bytes (gz)
>>>
>>> Indeed, that Quotation alone requires a 32x32 QR code.
>>>
>>>>> However, since invoices/offers and UBL are both structures, we
>>>>> should have an explicit mapping between the two. What fields should
>>>>> have their own existence in the invoice/offer and what should be in a
>>>>> general UBL field is a question we have to think on further.
>>>> I agree that we don't want duplication. This is the reason, I propose to
>>>> use only ubl structure and add in the ln standard invoice an ubl
>>>> "opaque" field which will be self-contained and only add in the
>>>> invoice/offer/.. the fields specific to ln.
>>> Except we need to go through the UBL spec and indicate exactly what
>>> fields are permitted, and which are required.
>>>
>>> Many UBI fields are not amenable to machine interpretation (eg. note
>>> fields). These must be either explicitly exposed to the buyer (in case
>>> the seller uses them) such as shipping conditions, or explicitly
>>> forbidden/ignored.
>>>
>>> This is not a small task, and required intimiate knowledge of the UBL
>>> spec. It's not enough just to make something *look* like UBL.
>>>
>>> Does anyone have expertise in this area? Shall we form a sub-group to
>>> investigate this properly?
>>>
>>> Thanks!
>>> Rusty.
>>>
Published at
2023-06-09 12:57:19Event JSON
{
"id": "f0cd8b9823e8b4f2d2ad0e1ba4154b56139d7f67ace101476089cdf3e36256c2",
"pubkey": "13fd0434c7ac300f7a468a5ad9464b7b94e8b03d7ae88259f3de3a84422822fd",
"created_at": 1686315439,
"kind": 1,
"tags": [
[
"e",
"a9016896e78ef5f5473204edd89280667686b471d7f529d125afce8e0e678ed9",
"",
"root"
],
[
"e",
"78183e8664da229503f185fa977cb92d5c315dd8bad5daafda98b5df83db7258",
"",
"reply"
],
[
"p",
"13bd8c1c5e3b3508a07c92598647160b11ab0deef4c452098e223e443c1ca425"
]
],
"content": "๐
Original date posted:2019-11-13\n๐ Original message:\nOn 13/11/2019 05:44, Rusty Russell wrote:\n\u003e Yaacov Akiba Slama \u003cya at slamail.org\u003e writes:\n\u003e\u003e ย Seller: Quotation (UBL)\n\u003e\u003e\n\u003e\u003e ย Buyer: Order (UBL)\n\u003e\u003e\n\u003e\u003e ย Seller: Prepayment Invoice (UBL)\n\u003e\u003e\n\u003e\u003e ย Seller: Invoice (LN)\n\u003e\u003e\n\u003e\u003e ย Buyer/Seller: Payment \u0026 Ack (LN)\n\u003e\u003e\n\u003e\u003e ย Seller: Receipt (UBL)\n\u003e\u003e\n\u003e \n\u003e This would be UBL treating Lightning as a dumb payment layer, which is a\n\u003e little like faxing email, and not a use case I'd be promoting for\n\u003e Lightning.\n\nI don't understand the comparison. Both email an fax are way to transmit\ndata and are not related to the *content* of what is transmitted.\nConsequently email and fax are in competing as a way to transmit data.\nBut LN and UBL (as I understand them) are not in competition because:\n\n* LN is a messaging protocol (soon) and a payment protocol.\n\n* UBL is a protocol defining business interaction workflow *around*\npayments.\n\nSo we can integrate between them without intermixing the semantics of\nthe protocols but we need only to define the interaction points between\nthem.\n\nIn the previous worflow, the seller can for instance add in the LN\ninvoice H(Quotation (UBL)||Order(UBL)||Prepayment Invoice(UBL)), and use\nH(Receipt(UBL)) as preimage. With such a workflow, the UBL documents are\ncryptographically tied to the LN payment.\n\nSo the property of UBL of not being machine *handlable* is not altered\nbut the LN cryptographic properties are still used to tie the workflow.\n\nAm I missing something?\n\n--yas\n\n\u003e\n\u003e To be clear: the full UBL spec is machine *parsable* but definitely not\n\u003e designed to be machine *handlable*. This makes sense, since a machine\n\u003e cannot generally choose between quotations or interpret general contract\n\u003e terms.\n\u003e\n\u003e However, for the simpler (but very common!) case of an offer-\u003epurchase\n\u003e flow, we can define a subset of UBL for which this *can* be done, and a\n\u003e further-limited subset which must be examined by the user\n\u003e (e.g. description of goods, price details, shipping info).\n\u003e\n\u003e In addition, the atomic nature of LN needs to be baked into the\n\u003e protocol; in LN taking the payment *requires* a cryptographic receipt,\n\u003e and neutering this property would be horribly short-sighted.\n\u003e\n\u003e We need to define UBL extensions for the LN fields to tie them all\n\u003e together (e.g. payment_hash, node_id). We also need to define a\n\u003e transport mechanism for these over the Lightning Network.\n\u003e\n\u003e This is all quite possible! But it will take time and is a signficant\n\u003e amount of work: I need to be sure that others feel the same way before I\n\u003e embark on this project.\n\u003e\n\u003e Cheers,\n\u003e Rusty.\n\u003e\n\u003e\u003e\u003e It's also worth noting that, even compressed, none of the UBL examples\n\u003e\u003e\u003e fit into the 1023 byte limit of the existing invoice format:\n\u003e\u003e\u003e\n\u003e\u003e\u003e UBL-Quotation-2.1-Example.xml: 1864 bytes (gz)\n\u003e\u003e\u003e UBL-Order-2.1-Example.xml: 2515 bytes (gz)\n\u003e\u003e\u003e UBL-Invoice-2.1-Example.xml: 3163 bytes (gz)\n\u003e\u003e\u003e\n\u003e\u003e\u003e Indeed, that Quotation alone requires a 32x32 QR code.\n\u003e\u003e\u003e\n\u003e\u003e\u003e\u003e\u003e \tHowever, since invoices/offers and UBL are both structures, we\n\u003e\u003e\u003e\u003e\u003e should have an explicit mapping between the two. What fields should\n\u003e\u003e\u003e\u003e\u003e have their own existence in the invoice/offer and what should be in a\n\u003e\u003e\u003e\u003e\u003e general UBL field is a question we have to think on further.\n\u003e\u003e\u003e\u003e I agree that we don't want duplication. This is the reason, I propose to \n\u003e\u003e\u003e\u003e use only ubl structure and add in the ln standard invoice an ubl \n\u003e\u003e\u003e\u003e \"opaque\" field which will be self-contained and only add in the \n\u003e\u003e\u003e\u003e invoice/offer/.. the fields specific to ln.\n\u003e\u003e\u003e Except we need to go through the UBL spec and indicate exactly what\n\u003e\u003e\u003e fields are permitted, and which are required.\n\u003e\u003e\u003e\n\u003e\u003e\u003e Many UBI fields are not amenable to machine interpretation (eg. note\n\u003e\u003e\u003e fields). These must be either explicitly exposed to the buyer (in case\n\u003e\u003e\u003e the seller uses them) such as shipping conditions, or explicitly\n\u003e\u003e\u003e forbidden/ignored.\n\u003e\u003e\u003e\n\u003e\u003e\u003e This is not a small task, and required intimiate knowledge of the UBL\n\u003e\u003e\u003e spec. It's not enough just to make something *look* like UBL.\n\u003e\u003e\u003e\n\u003e\u003e\u003e Does anyone have expertise in this area? Shall we form a sub-group to\n\u003e\u003e\u003e investigate this properly?\n\u003e\u003e\u003e\n\u003e\u003e\u003e Thanks!\n\u003e\u003e\u003e Rusty.\n\u003e\u003e\u003e",
"sig": "1b0d444c76a94cb86ab5932d00eb549161e2519fb1b493c80dd520fbb19b01122c4f902ea316398bd6d9e9fe66081e8a39b58cb9f8db70608d8de57ef1d526ab"
}