mirror of
https://github.com/bitcoin/bips.git
synced 2026-04-20 16:28:39 +00:00
correctly label witness_utxo vs non_witness_utxo key in supplementary inputs Summary of test vector changes: removed test: - psbt structure: empty PSBT_OUT_SCRIPT field when sending to non-sp output modified test: - ecdh coverage: only one ineligible P2SH multisig input when PSBT_OUT_SCRIPT set for sp output - can finalize: one P2PKH input single-signer - can finalize: two inputs using per-input ECDH shares - only eligible inputs contribute shares (P2SH excluded) added test: - can finalize: two inputs using global ECDH share - only eligible inputs contribute shares (P2SH excluded)
BIP-375 Validation Reference
A reference validation implementation for BIP-375: Sending Silent Payments with PSBTs.
Core Files
validator/bip352_crypto.py- Silent payment output script derivationvalidator/inputs.py- PSBT input utility functionsvalidator/psbt_bip375.py- BIP-375 specific PSBT/PSBTMap extensionsvalidator/validate_psbt.py- Main BIP-375 validation functionstest_runner.py- Test infrastructure (executable)
Dependencies
deps/bitcoin_test/psbt.py- Bitcoin test framework PSBT module - PR #21283deps/bitcoin_test/messages.py- Bitcoin test framework primitives and message structuresdeps/dleq.py- Reference DLEQ implementation from BIP-374deps/secp256k1lab/- vendored copy of secp256k1lab library at version 1.0.0
Testing
Run Tests
python test_runner.py # Run all tests
python test_runner.py -v # Verbose mode with detailed validation status
python test_runner.py -vv # More verbose with validation check failure reason
python test_runner.py -f vectors.json # Use custom test vector file
Generating Test Vectors
Test vectors were generated using test_generator.py