Remove two BIP32 vectors #1512

pull junderw wants to merge 1 commits into bitcoin:master from junderw:bip32-remove-vectors changing 1 files +1 −2
  1. junderw commented at 10:24 pm on November 17, 2023: contributor

    Two of the BIP32 vectors imply that the 4 byte version possibility space is limited.

    However, the BIP itself is unclear about whether anything besides the 4 versions xpub, xprv, tpub, tprv is valid or not. Parenthesis is not sufficient.

    Since BIP32 doesn’t prescribe anything in regards to derivation scheme (it only suggests one as an example), or script type (it makes no mention and keeps the topic only on deriving keypairs).

    So prescribing the version field as “it MUST be one of these 4 values” seems odd.

    In the 11 years since adoption, there have been plenty of uses of BIP32 HD keys with alternative versions, both within and outside of the Bitcoin mainnet and testnet networks. (zprv etc. is one such example)

    tl;dr We should make it clear that any version is valid BIP32, but that 4 specific ones are prescribed a meaning of “pertaining to mainnet” and “pertaining to testnet”.

    Alternatively: We should specify that bip32 should only treat those 4 versions as valid, all other MUST hard fail.

  2. Remove BIP32 vectors
    2 of the BIP32 vectors imply that the 4 byte version possibility space is limited.
    d4ac4d5a31
  3. luke-jr added the label Proposed BIP modification on Dec 26, 2023
  4. luke-jr commented at 7:36 pm on December 26, 2023: member
  5. luke-jr assigned sipa on Dec 26, 2023
  6. sipa commented at 6:03 pm on January 5, 2024: member
    It was certainly intended to mean “only these 4 prefixes are valid”, but in retrospect, that’s not a particularly useful stance. If you’d feel like clarifying more, I’d state it as “for mainnet the values must be xprv or xpub, and for testnet the values must be tprv or tpub” - what anyone does outside of those is out of scope anyway. But, as far as I’m concerned, things like zpub etc. are not BIP32 keys.
  7. junderw closed this on Jan 6, 2024


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bips. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-12-21 18:10 UTC

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