From: Matt Corallo <649246+TheBlueMatt@users.noreply.github.com> Date: Tue, 12 Nov 2024 20:23:45 +0000 (+0000) Subject: Merge pull request #3264 from jkczyz/2024-08-remove-user-provided-payer-id X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=70add1448b5c36368b8f1c17d672d8871cee14de;p=rust-lightning Merge pull request #3264 from jkczyz/2024-08-remove-user-provided-payer-id Disallow user-provided `payer_signing_pubkey` --- 70add1448b5c36368b8f1c17d672d8871cee14de diff --cc lightning/src/offers/invoice.rs index e7e459690,59100f4cf..3539d0f81 --- a/lightning/src/offers/invoice.rs +++ b/lightning/src/offers/invoice.rs @@@ -1763,10 -1772,9 +1772,10 @@@ mod tests amount: None, features: None, quantity: None, - payer_id: Some(&payer_pubkey()), + payer_id: Some(&invoice.payer_signing_pubkey()), payer_note: None, paths: None, + offer_from_hrn: None, }, InvoiceTlvStreamRef { paths: Some(Iterable(payment_paths.iter().map(|path| path.inner_blinded_path()))), diff --cc lightning/src/offers/invoice_request.rs index f7f1c2287,0e6ebb8cc..2594c056f --- a/lightning/src/offers/invoice_request.rs +++ b/lightning/src/offers/invoice_request.rs @@@ -1511,10 -1387,9 +1417,10 @@@ mod tests amount: None, features: None, quantity: None, - payer_id: Some(&payer_pubkey()), + payer_id: Some(&invoice_request.payer_signing_pubkey()), payer_note: None, paths: None, + offer_from_hrn: None, }, SignatureTlvStreamRef { signature: Some(&invoice_request.signature()) }, ExperimentalOfferTlvStreamRef { @@@ -2737,10 -2565,9 +2596,10 @@@ assert_eq!( fields, InvoiceRequestFields { - payer_signing_pubkey: payer_pubkey(), + payer_signing_pubkey: invoice_request.payer_signing_pubkey(), quantity: Some(1), payer_note_truncated: Some(UntrustedString("0".repeat(PAYER_NOTE_LIMIT))), + human_readable_name: None, } );