← Back to Bitcoin Improvement Proposals
BIPinformationalkey-managementscript

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

*Replaces https://github.com/bitcoin/bips/pull/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”), `0x

No reviews
jonatack·Updated Mar 21, 2025·0 reviews·0 attestations·View source
Collections:BIPs — Merged

Specification

Replaces https://github.com/bitcoin/bips/pull/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:

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

Smallest “possible” key:

kS = 0x043583940000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 (78 bytes)
b58chk(kS) = tprv8ZgxMBicQKsPcsbCVeqqF1KVdH7gwDJbxbzpCxDUsoXHdb6SnTPYxdwSAKDC6KKJzv7khnNWRAJQsRA8BBQyiSfYnRt6zuu4vZQGKjeW4YF
len(b58chk(kS)) = 111

Discussion (0 threads)

Loading discussions...