1 suggestion
Earlier concerns neither republished nor resolved: 1 minor finding. See the Run archive for their assessments.
Optional improvements
[suggestion] · Future-witness transaction exclusion lacks test coverage
The new Python oracle's vector tests never exercise the transaction-wide witness-v2+ exclusion, so removing that guard would leave their assertions unchanged.
Location: test/functional/test_framework/bip352.py:58 (head).
Details and suggested fix
The selected receiving vectors contain no witness-v2+ prevout, and there is no separate constructed case for this branch. Add a positive control with eligible Taproot inputs and a matching payment output, then append an input whose prevout is OP_2 followed by a 32-byte push and assert that scan() returns []. Choose the added outpoint so it does not change the smallest serialized outpoint used in the input hash. This makes the test distinguish skipping the entire transaction from merely omitting the future-witness input.
Earlier concerns
Earlier reports raised these, with the titles and severities shown there. This review neither republished nor resolved them.
- [minor]: Empty witnesses crash the scanner or change input eligibility (earlier report)
Background
Ralph's summary of historical context for the behaviour affected by this change. The historical record reviewed here is incomplete.
Documented decisions
BIP352 was proposed as an interoperability specification for wallets, accompanied by a Python reference implementation and sending/receiving test vectors—not as a description of one Bitcoin Core implementation.
This establishes the intended authority for the new independent oracle: BIP352's specified receiving behavior and its vectors. The head's test_framework/bip352.py loads the already-present vector file and selects cases with empty labels. Its independence from bitcoind concerns implementation, not independence from the protocol's eligibility rules.
Ralph's inferences
The two exclusions operate at different levels: future witness versions disqualify the transaction, whereas the recognized Taproot NUMS-H script-path case excludes only that input from shared-secret aggregation.
At the pinned head, scan() returns immediately if any prevout is a witness program with version >=2; get_input_pubkey() instead returns None for a script-path control block whose internal key is H, after removing an annex. The pinned base already expresses the same distinction in GetSilentPaymentsPrevoutsSummary() and GetPubKeyFromInput(). Moreover, the existing 'Single recipient: taproot input with NUMS point' receiving vector has labels=[], two H-internal-key script-path inputs—one with an annex—and one ordinary Taproot input. Its expected aggregate contains only the ordinary input's key, and it still expects a payment. Thus the receiving-vector baseline concretely distinguishes input omission from transaction rejection. This is an interpretation of inspected pinned code and data; the historical proposal establishes the vectors' interoperability role.
These exclusions are appropriate baseline assumptions for an unlabeled BIP352-v0 receiving oracle; omitting labels does not imply omitting transaction or input eligibility rules. This conclusion does not establish conformance with every specification edge case.
Both exclusions determine the aggregate input key before the head derives the shared secret or searches for recipient outputs. Label handling is downstream of those decisions. The inspected empty-label NUMS vector directly includes that exclusion in the selected test domain. The witness-version rule likewise defines the v0 transaction domain, rather than a label feature. The historical proposal's stated goal of wallet interoperability supports using one shared baseline, while the retrieval limitations prevent identifying an exact specification revision or claiming independently verified vector coverage for the future-witness branch.