Fix BIP143 standardness rules for CHECKMULTISIG #33759

pull roconnor-blockstream wants to merge 1 commits into bitcoin:master from roconnor-blockstream:bip143-standardness-2025-10 changing 1 files +19 −7
  1. roconnor-blockstream commented at 1:54 am on November 1, 2025: contributor

    From https://github.com/bitcoin/bips/blob/master/bip-0143.mediawiki#restrictions-on-public-key-type

    As a default policy, only compressed public keys are accepted in P2WPKH and P2WSH. Each public key passed to a sigop inside version 0 witness program must be a compressed key: the first byte MUST be either 0x02 or 0x03, and the size MUST be 33 bytes. Transactions that break this rule will not be relayed or mined by default.

    PR #8499 ’s implemenation is insufficent to meet BIP143’s requirements as it only checks those pubkeys processed by CHECKMULTISIG, whereas BIP143 requires that every public key passed to the CHECKMULTISIG be validated.

    Note: these restrictions are policy only and not consensus rules.

  2. Fix BIP143 standardness rules for CHECKMULTISIG
    From https://github.com/bitcoin/bips/blob/master/bip-0143.mediawiki#restrictions-on-public-key-type
    
    > As a default policy, only compressed public keys are accepted in P2WPKH and
    > P2WSH. Each public key passed to a sigop inside version 0 witness program must
    > be a compressed key: the first byte MUST be either 0x02 or 0x03, and the size
    > MUST be 33 bytes. Transactions that break this rule will not be relayed or mined
    > by default.
    
    PR #8499 's implemenation is insufficent to meet BIP143's requirements as it
    only checks those pubkeys processed by CHECKMULTISIG, whereas BIP143 requires
    that every public key passed to the CHECKMULTISIG be validated.
    
    Note: these restrictions are policy only and not consensus rules.
    e203010215
  3. DrahtBot commented at 1:54 am on November 1, 2025: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/33759.

    Reviews

    See the guideline for information on the review process. A summary of reviews will appear here.

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #33755 (Relax standardness rules regarding CHECKMULTISIG by roconnor-blockstream)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-11-02 18:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me