Skip to content

common: add BOLT12 payer proof support#8990

Open
vincenzopalazzo wants to merge 5 commits intoElementsProject:masterfrom
vincenzopalazzo:codex/payer-proof-1295
Open

common: add BOLT12 payer proof support#8990
vincenzopalazzo wants to merge 5 commits intoElementsProject:masterfrom
vincenzopalazzo:codex/payer-proof-1295

Conversation

@vincenzopalazzo
Copy link
Collaborator

@vincenzopalazzo vincenzopalazzo commented Mar 25, 2026

Summary

  • add common-layer payer proof encode, decode, and verification support for the lnp BOLT12 proof format
  • expose payer proof decoding through decode, bolt12-cli, and type guessing in the offers plugin
  • add vector-backed payer proof tests covering the published payer-proof corpus, including note-bearing proofs and selective disclosure of an odd experimental TLV

Testing

  • make -j1 common/test/run-payer_proof
  • ./common/test/run-payer_proof
  • make -j1 plugins/test/run-decode_guess_type devtools/bolt12-cli plugins/offers
  • ./plugins/test/run-decode_guess_type
  • jq -r '.vectors[] | select(.expected.valid) | [.name, .expected.proof_bech32] | @tsv' /tmp/payer-proof-test-vectors/test_vectors.json | while IFS=$'\t' read -r name proof; do ./devtools/bolt12-cli decode "$proof" >/dev/null || { echo "$name"; exit 1; }; done
  • make -j1 common/test/run-bolt12_merkle common/test/run-bolt12-format-string-test
  • ./common/test/run-bolt12_merkle
  • ./common/test/run-bolt12-format-string-test

Changelog-None

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