Bolt12Invoice for Offer without signing_pubkey
authorJeffrey Czyz <jkczyz@gmail.com>
Tue, 23 Apr 2024 23:35:05 +0000 (18:35 -0500)
committerJeffrey Czyz <jkczyz@gmail.com>
Fri, 26 Apr 2024 23:14:09 +0000 (18:14 -0500)
commitb7635c4dc2a5202e64305d65eff36bd74df528d1
tree62a06dba5777b05a9d931c65c48824e286c40a01
parent61e4fcea8e19eba1f6b1299c8415031c3a031a94
Bolt12Invoice for Offer without signing_pubkey

When parsing a Bolt12Invoice use both the Offer's signing_pubkey and
paths to determine if it is for an Offer or a Refund. Previously, an
Offer was required to have a signing_pubkey. But now that it is
optional, the Offers paths can be used to make the determination.
Additionally, check that the invoice matches one of the blinded node ids
from the paths' last hops.
lightning/src/offers/invoice.rs
lightning/src/offers/invoice_request.rs