BIP-138 addresses a Bitcoin wallet recovery concern: how can cosigners keep an encrypted copy of the wallet’s configuration without having to remember another password? The proposal covers output script descriptors (BIP-380), wallet policies (BIP-388) and other wallet metadata, not the seed itself. A Chinese translation of the specification was published on November 26, 2026.
How recovery works. The proposed format uses BIP-340 tagged hashing to derive a shared secret, s, from the descriptor’s public keys in lexicographic order. It also derives an individual secret, s_i, for each eligible public key. The backup stores the XOR of the two secrets, s ⊕ s_i, in the clear. A cosigner can use their own public key to derive s_i and reverse the XOR, recovering s without another cosigner’s help. The payload is encrypted with ChaCha20-Poly1305.
What stays confidential. The design aims to prevent third parties from reconstructing the secret from on-chain information. Not every public key qualifies for recovery: the specification excludes literal public keys, bare extended public keys (xpubs) and publicly known NUMS points. Decoy entries obscure the number of cosigners, while padding to predefined length buckets conceals the exact payload length.
The format specifies a MAGIC identifier, a VERSION field, derivation paths, individual secret entries and ciphertext. It defines content types for descriptors, wallet policies and strings, with a type boundary at 0x80. The specification also includes the decryption procedure, test vectors and backward-compatibility notes.