Generate BIP39 Mnemonic
Make a suggestion Improve this page
The Key Generation Protocol will securely generate a BIP39 Mnemonic that will be used to store all your assets.
Through the BIP39 standard we will create 24 words (a mnemonic) which will then be used to derive private keys across protocols. Each signatory will only need to secure their 24-word phrase in order to be able to access funds .
By the end of this section, each signatory will generate the following information:
- A BIP39 Mnemonic: Also called a seed phrase, this is a 24-word combination that will later be used to unlock your funds across BTC, BCH, LTC, XRP & ETH. Each seed phrase should be created in a different device by a different signatory. In your M-of-N policy there should be N signatories each with 1 seed phrase. These phrases should always be separated and signatories should never see each other’s seed phrases.
- A Master public key for Bitcoin: An alphanumeric string to allow Electrum to generate the public keys for the BTC cold HD wallet
- A Master public key for Litecoin: An alphanumeric string to allow Electrum-LTC to generate the public keys for the LTC cold HD wallet
- A Master public key for Bitcoin Cash: An alphanumeric string to allow Electron-Cash to generate the public keys for the BCH cold HD wallet
- An XRP address: Address to give ownership of an XRP multisign account
- An ETH address: Address to give ownership of an ETH multisig contract
Only quarantined hardware should be used during the execution of the Key Generation Protocol.
Signatories should not be in close proximity of each other when executing the Key Generation Protocol. Signatory should always use distinct quarantined computers and should never ever share seed phrases.
- If this is not your first time working with CryptoGlacier:
- Use a networked computer to access the latest full release of CryptoGlacier ( not just the protocol document) at https://github.com/vogelito/CryptoGlacierProtocol/releases.
- Open the protocol document (CryptoGlacier.pdf) within the ZIP file.
- Check the Release Notes (Appendix E) of the protocol document to see if there are any new versions of CryptoGlacier recommended.
- Whether or not you decide to upgrade, review the errata for the version of CryptoGlacier you are using at https://github.com/vogelito/GlacierProtocol/releases.
- Execute Section VI of the Setup Protocol to prepare your quarantined workspace.
-
Create entropy for private keys
Creating an unguessable private key requires entropy – random data. We’ll combine two sources of entropy to generate our keys. This ensures securely random keys even if one entropy source is somehow flawed or compromised to be less-than-perfectly random.
- Generate dice entropy
- Type “DICE ENTROPY” into both Quarantined Scratchpads.
- Roll 62 six-sided dice, shaking the dice thoroughly each roll. 62 dice rolls corresponds to 160 bits of entropy. See the design document for details.
- If you are rolling multiple dice at the same time, read the dice left-to-right. This is important. Humans are horrible at generating random data and great at noticing patterns. Without a consistent heuristic like “read the dice left to right”, you may subconsciously read them in a non-random order (like tending to record lower numbers first). This can drastically undermine the randomness of the data, and could be exploited to guess your private keys.
- Manually enter the numbers into the Quarantined Scratchpad of ONLY ONE of the quarantined computers. Put all rolls on the same line to create one line of 62 numbers. (It’s fine to add spaces for readability.)
- Generate BIP39 seed phrase
- Make sure you are in the
~/cryptoglacier folder
:$ cd ~/cryptoglacier
- On the Q1 computer enter the following command to generate your
BIP39 seed phrase
$ node setup.js --init
- The script will prompt you to enter the 62-number line of dice entropy
- The script will output your cold storage data:
- Dice entropy
- Generated Computer entropy
- Final entropy
- BIP39 Mnemonic
- Bitcoin Master Public Key
- Litecoin Master Public Key
- Bitcoin Cash Master Public Key
- Ethereum Address
- Ethereum Private Key
- Ripple Address
- Ripple Private Key
Example output:
Dice entropy: 1111 1111 1111 1111 1111 1111 1111 1111 1111 1111 1111 1111 1111 1111 1111 11 Generated Computer entropy: aaaa aaaa aaaa aaaa aaaa aaaa aaaa aaaa aaaa aaaa Final entropy: ae29155ab1b3f5a1fc0c7cee883cd39457d273b9eb5eb6ac16a309bc7dd4d293 BIP39 Mnemonic: purchase emerge find gloom dismiss special usual moon update draft crunch chunk large degree tray hint repeat gaze potato beach sick tuna engage hand Bitcoin Master Public Key (Zpub): Zpub75EpZYVWcoTQ1WChsnabzLUAm91t379iNBPM647HvyuXg2Pn9DtkyVkLWicg4CJzbLKYcSzYV6B1yLTUbjq5LMqkhrzRDW7ebTEaUvxHhUL Litecoin Master Public Key (Zpub): Zpub75CcoXN1LVH6qE3MNYAAbd8f6c3pgJC8aT1L8crzZTifZQcjrJcJxRxL1o4UxLMHGg4YvBjDN8hHQaHrKsxsSwwApiX7b7goVDRQrpLLmB9 BitcoinCash Master Public Key (xpub): xpub6BjfaUaRAzkDfaYWKGNDxewXDUpgkJdPTB7jo4hcDfFG5QwX6JqJEEKg1at6FkwMVsFYPKf3KyKBSiK7i3gXdYaBNc8m2TEHNARwfWasdcX Ethereum Address: 0x6bff50edf67a2eae30e9eef7007b31292405ab2d Ethereum Private Key: 0xB31B0A016562839D6D6D137489924C56566312DD0167B197295DFF89D89C1C48 Ripple Address: rHzjZTF4nD1ta2oPz7EYvYKXx26n8ZKFUv Ripple private key: F477BA0925608BCBBF870078E17030DB132CBD7D3286B305A60312B9FB9D9729
- Type “COMPUTER ENTROPY” into both computers’ Quarantined Scratchpads. (This is a descriptive heading to keep your notes organized and minimize risk of error.)
- Copy-paste the Generated Computer entropy into the Quarantined Scratchpad.
- Manually enter the Generated Computer entropy into the Quarantined Scratchpad on the other quarantined computer.
- Make sure you are in the
-
Verify the integrity of the cold storage data
If there are discrepancies in any of the verification steps, please restart the protocol. If discrepancies continue, please DO NOT PROCEED and seek assistance.
- On the Q2 computer enter the following command:
$ node setup.js --check
- The script will prompt you to enter the 62-number dice entropy and the Generated computer entropy.
-
Verify that the BIP39 Mnemonic shown in the terminal window is identical on both computers.
Make sure you carefully verify every word.
There are attack vectors which could replace just a portion of BIP39 seed phrase, making the private keys easier to brute force, so it’s important to check them thoroughly.
- On the Q2 computer enter the following command:
$ python mnemonic_entropy.py entropy --integrity
-
The script will prompt you to enter the 62-number dice entropy and the Generated computer entropy.
Example output of the python script:
Generated Entropy (copy this string into bip39-standalone.html): ae29155ab1b3f5a1fc0c7cee883cd39457d273b9eb5eb6ac16a309bc7dd4d293
-
Verify that the Generated Entropy string shown in the terminal window is identical to the Final entropy string shown in the node script terminal output of the Q1 Computer.
-
- On the Q2 computer open bip39-standalone.html
$ firefox ~/apps/bip39-standalone.html
- Check the
Show entropy details
checkbox -
Copy the Generated Entropy output of the python script into the
Entropy
box in Firefox and verify that the BIP39 seed matches that of the node script terminal output of the Q1 Computer.Example output in the
BIP39 Mnemonic
section in Firefox:purchase emerge find gloom dismiss special usual moon update draft crunch chunk large degree tray hint repeat gaze potato beach sick tuna engage hand
Verify every word of the BIP39 Mnemonic so it matches the output of the scripts on both computers.
- In the
Coin
dropdown menu in Firefox, selectETH - Ethereum
- Verify that the derived Ethereum address
for the
m/44'/60'/0'/0/0
Path matches the Ethereum address output of the script on the Q1 computer. (Case insensitive) -
Verify that the derived Ethereum Private Key for the
m/44'/60'/0'/0/0
Path matches the Ethereum Private Key output of the script on the Q1 computer. (Case insensitive)For the Ethereum private key, verify each character. Again, there are attack vectors which could replace just a portion of private keys, making the private keys easier to brute force so it’s important to check them thoroughly. For Ethereum, both the private key and the address ARE NOT case sensitive.
- Verify that the derived Ethereum address
for the
- In the
Coin
dropdown menu in Firefox, selectXRP - Ripple
- Verify that the derived Ripple address
for the
m/44'/144'/0'/0/0
Path matches the Ripple address output of the script on the Q1 computer. -
Verify that the derived Ripple Private Key for the
m/44'/144'/0'/0/0
Path matches the Ripple Private Key output of the script on the Q1 computer.For the Ripple private key, verify each character. Again, there are attack vectors which could replace just a portion of private keys, making the private keys easier to brute force so it’s important to check them thoroughly.
- Verify that the derived Ripple address
for the
- Check the
- On the Q2 computer open Electrum
$ ~/apps/electrum-3.3.6-x86_64.AppImage
- Leave
default_wallet
and clickNext
. - Select
Multi-signature wallet
and clickNext
. - Select your
M-of-N
policy. The top bar,cosigners
is theN
and the lower bar,Required signatures
is theM
. ClickNext
. - Select
I already have a seed
and clickNext
. - Click on
Options
, selectBIP39 seed
and clickOK
. - Enter your BIP39 seed phrase and
click
Next
. - Leave
native segwit multisig (p2wsh)
selected and clickNext
. -
Verify that the Master Public Key is the same as the output of the script on the Q1 computer.
Again, please make sure you verify each character.
- Close the window (click on the top left
x
)
- Leave
- On the Q2 computer open Electrum-LTC
$ ~/apps/electrum-ltc-3.3.6.1-x86_64.AppImage
- Leave
default_wallet
and clickNext
. - Select
Multi-signature wallet
and clickNext
. - Select your
M-of-N
policy. The top bar,cosigners
is theN
and the lower bar,Required signatures
is theM
. ClickNext
. - Select
I already have a seed
and clickNext
. - Click on
Options
, selectBIP39 seed
and clickOK
. - Enter your BIP39 seed phrase and
click
Next
. - Leave
native segwit multisig (p2wsh)
selected and clickNext
. -
Verify that the Master Public Key is the same as the output of the script on the Q1 computer.
Again, please make sure you verify each character.
- Close the window (click on the top left
x
)
- Leave
- On the Q2 computer open Electron-Cash
$ ~/apps/Electron-Cash-4.2.3-x86_64.AppImage
- Leave
default_wallet
and clickNext
. - Select
Multi-signature wallet
and clickNext
. - Select your
M-of-N
policy. The top bar,cosigners
is theN
and the lower bar,Required signatures
is theM
. ClickNext
. - Select
I already have a seed
and clickNext
. - Click on
Options
, selectBIP39 seed
and clickOK
. - Enter your BIP39 seed phrase and
click
Next
. - Leave the default
m/44'/145'/0'
derivation path selected and clickNext
. -
Verify that the Master Public Key is the same as the output of the script on the Q1 computer.
Again, please make sure you verify each character.
- Close the window (click on the top left
x
)
- Leave
- On the Q2 computer open multisigweb
$ multisigweb
- Agree to the Terms of Use and Privacy Policy
- Select
Light Wallet
- Go to the
Accounts
tab and clickImport
- Click
Browse...
and go to Home -> cryptoglacier - Select the
ethereum.json
file and clickOpen
- In the password field enter
cryptoglacier
- In the account name field enter anything you’d like, such as
coolest signatory
- Click
Import Account
-
Verify that the Ethereum Address is the same as the output of the script on the Q1 computer.
Again, please make sure you verify each character.
- Close the window (click on the top left
x
)
- On the Q2 computer enter the following command:
- Generate dice entropy