1

Can the following be clarified, where I am wrong:

The Xpriv can derive a hardened xpriv.

It can also derive a non hardened xpriv, which we will use with the neutered function to make it an xpub.

The xpub derived, is the same xpub that we would get if we had done CKDpub on the original Xpub.

Xpirv and Xpub with the capital 'X' can be seen as parent keys.

So a diagram would look like:

Xpriv -> xprivH (hardened)

Xpriv -> xprivN -> xpubN (Normal: This is the path from the xpriv using Neuter)

Xpub -> xpubN (Normal: This is the same path from the Xpub using CKDpub)

My other question on top of this, is if a Wallet software has the mnemonic key, would it be better to always derive from the mnemonic?

Or would they keep the account level xpriv, it seems like a waste to have both the mnemonic and the account level xpriv on the device.

Also, Is the extended private key, the (private key + chain code), or is it the (magic + depth + fingerprint + index + chain + key) ?

1 Answer 1

3

It can also derive a non hardened xpriv, which we will use with the neutered function to make it an xpub.

The xpub derived, is the same xpub that we would get if we had done CKDpub on the original Xpub.

Yes. Neutering really means "Do CKDpub and delete the Xpriv". There is no neuter function on Xprivs; it's for the wallet software, not the key derivation.

My other question on top of this, is if a Wallet software has the mnemonic key, would it be better to always derive from the mnemonic?

Deriving from the mnemonic requires additional computation, however requires less storage space. I don't think it really matter.

Also, Is the extended private key, the (private key + chain code), or is it the (magic + depth + fingerprint + index + chain + key) ?

The second.

2
  • Thank you, I think I understand bip32 and 44 now. Thanks for all of the corrections Andrew. May 3, 2018 at 4:51
  • It is not accurate to state that "there is no neuter function on Xprivs". The function is defined in the spec as taking an extended private key for input: N((k, c)) → (K, c)
    – rnbrady
    Jun 2, 2020 at 15:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.