BIP32 amendment: base58chk-encoded extended keys are always 111 chars #1584

pull jonatack wants to merge 1 commits into bitcoin:master from jonatack:2024-04-bip32-amendment changing 1 files +1 −1
  1. jonatack commented at 9:56 pm on April 30, 2024: member

    Replaces #727 with with cherry-picked 81644ddfa131bb0e387ead2cc309ca18e57542b1; note that BIP32 has status Final. The description below is copied from that PR.

    Base58chk-encoded extended keys are always 111 characters long. Amend wording of BIP32 accordingly.

    Diff: -This results in a Base58-encoded string of up to 112 characters. +This results in a Base58-encoded string of exactly 111 characters.

    Proof: Version bytes: 0x0488b21e (“xpub”), 0x0488ade4 (“xprv”), 0x043587cf (“tpub”), 0x04358394 (“tprv”)

    Largest version byte is 0x0488b21e, smallest 0x04358394.

    Largest “possible” key:

    0kL = 0x0488b21effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff (78 bytes)
    1b58chk(kL) = xpubEPi3iGSX9RiyuXPTijevUmMctBDQs2TWCMgUd3qKp6qCgUc8RUsPdPBrRC6whFeWTg37DcmnJJiKFL73DH4sjdApJkXBD3vFcBP4xHq3fPY
    2len(b58chk(kL)) = 111
    

    Smallest “possible” key:

    0kS = 0x043583940000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 (78 bytes)
    1b58chk(kS) = tprv8ZgxMBicQKsPcsbCVeqqF1KVdH7gwDJbxbzpCxDUsoXHdb6SnTPYxdwSAKDC6KKJzv7khnNWRAJQsRA8BBQyiSfYnRt6zuu4vZQGKjeW4YF
    2len(b58chk(kS)) = 111
    
  2. Base58chk-encoded extended keys are always 111 characters long. Amend wording of BIP accordingly.
    -This results in a Base58-encoded string of up to 112 characters.
    +This results in a Base58-encoded string of exactly 111 characters.
    
    Version bytes: 0x0488b21e (“xpub”), 0x0488ade4 (“xprv”), 0x043587cf (“tpub”), 0x04358394 (“tprv”)
    
    Largest “possible” key:
       kL = 0x0488b21effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff (78 bytes)
       b58chk(kL) = xpubEPi3iGSX9RiyuXPTijevUmMctBDQs2TWCMgUd3qKp6qCgUc8RUsPdPBrRC6whFeWTg37DcmnJJiKFL73DH4sjdApJkXBD3vFcBP4xHq3fPY (111 chars)
    
    Smallest “possible” key:
       kS = 0x043583940000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 (78 bytes)
       b58chk(kS) = tprv8ZgxMBicQKsPcsbCVeqqF1KVdH7gwDJbxbzpCxDUsoXHdb6SnTPYxdwSAKDC6KKJzv7khnNWRAJQsRA8BBQyiSfYnRt6zuu4vZQGKjeW4YF (111 chars)
    f1c296bb32
  3. jonatack commented at 9:58 pm on April 30, 2024: member

    Replaces #727 with cherry-picked 81644ddfa131bb0e387ead2cc309ca18e57542b1; note that BIP32 has status Final.

    Pinging @sipa for feedback.

  4. jonatack added the label Proposed BIP modification on Apr 30, 2024
  5. murchandamus assigned sipa on May 1, 2024
  6. murchandamus added the label Pending acceptance on May 8, 2024
  7. jonatack commented at 3:00 pm on March 21, 2025: member
    cc @sipa for yay or nay
  8. sipa commented at 3:03 pm on March 21, 2025: member
    ACK f1c296bb3286eb7f46384298b22c67abe65a5bb8
  9. jonatack merged this on Mar 21, 2025
  10. jonatack closed this on Mar 21, 2025

  11. jonatack deleted the branch on Mar 21, 2025

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: 2025-04-19 12:10 UTC

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