-
Notifications
You must be signed in to change notification settings - Fork 300
feat: Verify BIP322 proofs in both transaction and psbt formats #6878
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Add functions to verify BIP322 message signatures. This includes verification of both fully signed transactions and PSBTs. The verification checks that: 1. The transaction follows BIP322 format requirements 2. Each input correctly references the expected message 3. Signatures are valid for the corresponding public keys BTC-2375 Co-authored-by: llm-git <llm-git@ttll.de> TICKET: BTC-2375
Add functions to verify BIP322 message signatures in transaction proofs. Implement support for both PSBT and regular transaction formats, with verification against provided message information. Co-authored-by: llm-git <llm-git@ttll.de> TICKET: BTC-2375
f5553ad to
531a83c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR implements BIP322 proof verification functionality to support validation of message signing proofs in both transaction and PSBT formats. This enables verification of signed messages using Bitcoin's BIP322 standard.
- Adds verification functions for BIP322 transactions and PSBTs with signature validation
- Implements comprehensive test coverage for all verification scenarios and edge cases
- Introduces transaction/PSBT proof verification in the abstract-utxo module
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| modules/utxo-core/src/bip322/verify.ts | Core verification logic for BIP322 proofs with transaction and PSBT validation functions |
| modules/utxo-core/test/bip322/verify.ts | Comprehensive test suite covering all verification scenarios and error cases |
| modules/utxo-core/src/bip322/toSign.ts | Updates base PSBT creation to accept configurable network parameter |
| modules/utxo-core/src/bip322/index.ts | Exports the new verify module functions |
| modules/abstract-utxo/src/transaction/bip322.ts | High-level verification functions for broadcastable messages |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
BTC-2375