Does a wallet containing multiple addresses have a single private key?

17

7

Title says it all. Would one private key enable you to recover all the addresses in your wallet? Or does a wallet just contain a series of key-pairs?

Leftover Salad

Posted 2013-12-06T04:34:37.397

Reputation: 377

Answers

13

There are three main types of wallets:

  1. non-deterministic (random) wallets
  2. sequential deterministic wallets
  3. hierarchical deterministic wallets

With a non-deterministic (random) wallet, all the private/public keypairs are generated randomly. The wallet may generate 100 random private keys as soon as it is initialized, for example.

With a sequential deterministic wallet, a passphrase or sequence of characters is randomly generated to act as a seed. It is then repeatedly incremented and hashed to generate new private keys.

With a hierarchical deterministic wallet, a single keypair is created initially and is known as the master keypair. This master keypair is used to generate child keypairs (remarkably, new bitcoin addresses can be generated using just the public key).

Here's a more in-depth explanation: What is a deterministic wallet?

Also, here's my python implementation of a sequential deterministic wallet. And here's a good example of a hierarchical deterministic wallet.

Ryan

Posted 2013-12-06T04:34:37.397

Reputation: 737

10

There's two types of wallet. A conventional wallet is just a collection of random keys, Bitcoin-QT and Multibit fit into this category. A Hierarchical Deterministic like Electrum or Armory generate all the keys in the wallet from a single key, so that one backup is permanently associated with a wallet no mater how many new addresses and change addresses are used.

https://en.bitcoin.it/wiki/BIP_0032

Anonymous

Posted 2013-12-06T04:34:37.397

Reputation: 1 330

Thanks for the reply. That article was over my head, but if I'm understanding this correctly--normal wallets will generate a number of key-pairs, but a HD wallet will generate a bunch of public keys for a given private key?Leftover Salad 2013-12-06T06:06:57.180

That's right, though a HD wallet will derive private keys from a master key using a specific standard method, rather than using it directly.Anonymous 2013-12-06T06:09:56.570