https://pixabay.com/photos/dice-game-craps-multicoloured-568059/

How to generate a mnemonic seed with AnuBitux and a dice

In a previous post, we have seen how to obtain a paper wallet by rolling a dice 256 times and tracking results with dicetracker.py, a tool developed by the AnuBitux team. This tool supports the creation of paper wallets for many different currencies but not for all. Let's now see how to obtain a BIP39 valid mnemonic seed starting from the entropy obtained by rolling a dice many times. This way, we can use this mnemonic seed to derive private keys and addresses for many different kinds of coins. This is how this tool works!

OpSec first!

When generating a new mnemonic seed, it is very important to pay a lot of attention to the procedure we are using. If something goes wrong or if we leak some information, we could lose our coins. For this purpose, if we use it properly, AnuBitux could give us great help.

Let's begin starting AnuBitux live from our USB stick! Working in a live environment will leave no traces of what we are doing on the internal drives of our devices. Then, to be sure no information is leaving our devices, let's use the 'Offline' script placed on the upper left corner of our home screen.

offline

Now, if we are in a safe place, without any recording device or indiscreet eyes around us, we can start generating our new mnemonic seed.

Generating entropy

First of all, let's start the tool Dice2Seed.py, by simply typing its name in our terminal window.

dice2seed1

The tool first of all asks us how many bits of entropy we want to obtain to generate our seed. This will affect the length of our mnemonic seed, according to the following scheme.

scheme

In the first column, we have the bits of entropy, in the second the bits of the checksum (obtained from bits of entropy / 32), in the third the length in bits of our seed and in the fourth the number of words of our mnemonic seed. This depends on how seeds are generated from entropy:

  • sha256 hash is calculated on our entropy;
  • a checksum is obtained with a bit of the sha256 result for every 32 bits of entropy;
  • checksum is appended to entropy, giving us the seed;
  • seed is divided into groups of 11 bits (adding a bit every 32 bits of entropy, our seed's length will always a multiple of 33, that is itself a multiple of 11);
  • every 11 bits group is converted to decimals and gives us the index of the word in the bip39 wordlists, since a number of 11 can give a decimal between 0 and 2047. For this reason, we have 2048 words in the bip39 wordlists.

In our case, let's hypothesize we want to obtain a mnemonic seed starting from 128 bits of entropy.

dice2seed2

Now we will be prompted to paste the result of 128 previously made dice rolls or we can use the tool to track the rolls we are making while running it.

In this case, we will paste a 128 digits string, but we could also paste an entropy string made by 0s and 1s or use the tool to help us to track dice rolls.

dice2seed3

Obtaining the mnemonic seed

Now we only have to choose the language we prefer for our mnemonic seed, indicating the corresponding number, and mission complete! We obtained our mnemonic seed!

dice2seed4

How to use our seed

Now we can use our seed accordingly to our needs:

  • we could paste it in our BIP39 compatible wallet and start receiving and disposing transactions;
  • we can use it with our hardware wallet;
  • we can derive private keys and addresses with the Ian Coleman's BIP39 tool, that is already available in AnuBitux without the need to connect to the Internet.

The last solution could be a good one if we are using this procedure to arrange a safe cold storage for our coins. To do it, we can start the Ian Coleman's tool from the WalletTools menu in AnuBitux, and paste our mnemonic seed in the corresponding box.

iancoleman1

Then we only have to choose the coin of which we want to have private keys and addresses and, scrolling down the page, we will find all that we need to prepare our cold storage.

iancoleman2

Now we can choose one or more addresses, with the related private key, and prepare a paper wallet to store in a safe place. If we also want to generate QR codes for our paper wallet, we can use the qrencode tool:

qrencode

Of course, if we are intended to use the generated addresses only to receive coins and store them in a safe place, it might be enough to take note only of the public addresses. If in the future we will need to spend our coins, we could do that in a BIP39 compatible wallet.

We could also use the Ian Coleman's tool to obtain addresses of many different coins from the same mnemonic seed.

We should also be able to print our paper wallets without the need to connect to the Internet, exposing our working environment, since AnuBitux has a lot of printer drivers already installed.

Final thoughts

When generating a mnemonic seed or a paper wallet, no care is enough! These are very sensible operations and doing some mistakes or operating with carelessness could compromise our funds. Cryptocurrencies are great because they let us be our bank, but this also implies that we are responsible for our funds.

We should also pay attention to the tools we use during our process. We should prefer simple and open-source tools, that we could easily inspect to be sure about how they handle our precious information. 

This article was updated on 26 Oct 2023