WO-12 — Transactions

Branch: wo-12-tx from wo-11-slh-dsa at ac54f39.

Implemented canonical §2g transaction serialization with minimal CompactSize encodings, strict trailing-byte rejection, witness-free txid, full wtxid, and sighash committing to each spent output’s value, type, and varbytes payload. Output validation covers types 0x00–0x04; types 0x05–0xFF remain consensus-valid and are flagged non-standard. Typed witnesses are parsed against supplied spent-output metadata, and single-owner, shared, and Block QTL signatures are verified through WO-11 keys with the default empty context.

Coinbase validation enforces one null-prevout input, lock_time == block_height, and an 8-byte extranonce followed by at most 100 bytes. The witness-commitment helper uses the bound transaction Merkle root after replacing the first (coinbase) wtxid with 32 zero bytes. Ordinary transaction validation enforces 100-block coinbase maturity, per-output and checked-sum caps at T, and outputs no greater than inputs.

The independent Python reference and frozen WO-12 vectors are in e46/golden/transaction_reference.py and e46/golden/wo12-golden.json; the generator’s --check passes. C++ matched all frozen vectors and 1,000 fresh randomized transactions, including CompactSize edges and sighash sensitivity to spent value/type/payload. Malformed, non-minimal, truncated, trailing-byte, bad-height, and oversize cases are rejected. No earlier golden file was edited, and the WO-12 implementation contains no SHA-2 use.

Validation on macOS arm64 with OpenSSL 3.6.5:

  • Release: all 31 CTest tests passed, including WO-12 unit, differential, and golden-reproducibility tests.

  • ASan/UBSan: all 31 CTest tests passed.

  • libFuzzer with ASan/UBSan: 100,000 runs from empty input and 100,000 runs seeded with the five frozen transaction vectors; no crash or sanitizer finding. The system Clang 21 fuzzer runtime was unavailable, so this target was built and run with Homebrew Clang 22.1.8.

No new decision was needed. UTXO lookup, block-level validation of the computed witness commitment, and Block QTL commitment-depth checks remain outside this transaction work order.