Many investors are annoyed with making backups, as they normally have multiple tokens whose backup needs to be stored separately. So, is there a wallet that can greatly simplify the backup making process for multiple chains? Is there a way to manage all wallets by one set of mnemonic words? The answer is HD Wallet! HD wallet, namely Hierarchical Deterministic Wallet, is currently the best and most convenient deterministic wallet.
Non-deterministic wallets vs deterministic wallets
Different private key generation methods correspond to different wallet structure.
Non-deterministic wallets, also known as random wallets, are characterized by no relation between private keys. The earliest Bitcoin wallets belong to this category. To back up all addresses in a wallet at the time, all private keys need to be restored separately, which made backup management an extremely tedious thing. So deterministic wallets came into being to solve the problem.
Deterministic wallets, also known as seed wallets, feature that all key pairs are generated from one same seed. The advantage of a deterministic wallet is that all private keys can be restored with one seed, which is very convenient for backup and restoration. Seeds randomly generated by deterministic wallets produce a series of key pairs through a series of deterministic and irreversible calculations. ‘Deterministic’ ensures that a seed can generate all subkey pairs and ‘irreversible’ implies that seeds can not be obtained by the subkey pair.
Hierarchical deterministic wallet (HD wallet)
The concept of HD wallet was first seen in the BIP32 protocol, and it is also the most common deterministic wallet at present. HD optimized the structure of deterministic wallets and produces private keys through a hierarchical tree-like structure. First, the seed generates a master key pair, and the master keypair derives many sub-key pairs, and the sub-key pairs can continue to derive indefinitely. The derivation process of the HD wallet also follows the principle of ‘deterministic’ and ‘irreversible’.
Such a tree-like structure and derivation principle can not only facilitate the management of a large number of key pairs but also enhance the decentralization of key management and increase organizational management capabilities. The parent key has absolute control over the assets in the subkeys. The subkey can control the assets in itself, but it does not have authority over the assets in the same level keys or parent keys.
Mnemonic Wallets VS HD Wallets
The seed in HD wallets, however, has a great challenge — although compared to deterministic wallets, HD wallets are more convenient as only one seed needs to be remembered, but the seed in the BIP32 protocol has128 characters and is extremely hard to remember!
An example of seed：d4f9e64aff329ce0d1d7f57df9ec91cfbb1e40d7f9a94ecea7881aa944366a9c0fe1c326af5a072427f86ceb73d48e11169772b0077a1230b7f04a7edaf927dc
BIP39 protocol proposed a mnemonic generator solution to tackle this challenge: a seed can be obtained by a series of randomly generated mnemonic. The English-language wordlist for the BIP39 standard has 2048 words. The algorithm change will be conducted on a random sequence after it is generated to get a new sequence. The new sequence will be divided into several parts and each part will correspond to a word on the wordlist, hence a mnemonic will be generated. The mnemonic can then generate the seed through the key generation function PBKDF2. So, we can conclude the entire HD wallet creation process as the following: mnemonic — seed — key — address.
An example of mnemonic:
crew code snow thing onion hybrid polar kid arctic reject meat pioneer cherry tree change
However, the advantages of HD wallets do not end here. The BIP44 protocol gives a new definition to every layer in the tree-like structure — each layer can support multiple chains, which means that HD wallet users can control multiple assets through one master key or a group of mnemonic.
HD wallets have a more convenient management solution and are able to efficiently generate addresses on multiple public chains, back up multiple assets with one group of mnemonic. TokenPocket will launch the HD wallet for our users very soon. Please follow us for an upcoming detailed tutorial!