APC Australia

Safely store cryptocurr­ency on a Raspberry Pi

Put your Bitcoins on ice and use a Raspberry Pi as a cold wallet to store all your digital currency safely offline.

-

As you’re probably aware, the cryptocurr­ency Bitcoin can be used to make anonymous and irreversib­le online payments, similar to hard cash. Bitcoin is a huge leap forward for privacymin­ded people, but the fact that it’s a digital currency means that hackers often target owners of Bitcoin software wallets. In this tutorial, we’ll explore a solution using the lightweigh­t Bitcoin Wallet Electrum on the Raspberry Pi. The Pi will host a ‘cold’ wallet which is kept offline at all times.

You’ll also set up an online ‘watching’ wallet on another computer so you can see payments as they come in. Payments are only sent by generating a transactio­n file with your watching wallet, which you transfer manually via a USB stick to your ‘cold’ wallet to be digitally signed.

As your cold wallet is offline, only people with physical access to it can make payments, which enables you to store Bitcoins safely.

This guide assumes that you are familiar with the basics of Bitcoin. If not, then visit this useful introducti­on page bit.ly/2m7Ct2X for a rundown.

1 INSTALL SOFTWARE

Connect the Pi to a screen and keyboard. Open Terminal and run these two commands:

sudo apt-get update sudo apt-get upgrade

For security reasons, you should only use this Pi as a wallet for future purchases.

The Raspbian repositori­es (repos) have an old version of the Electrum wallet, but it is best to download the latest version manually.

Next, run the following two commands to install the latest wallet software with

sudo apt-get install python-qt4 then sudo pip install download.electrum.org /2.7.18/Electrum-2.7.18.tar.gz.

2 DISCONNECT FROM THE INTERNET

This step is essential for ensuring your wallet is safe. Remove any network cables and/or Wi-Fi adaptors connected to your Pi. If you use a Pi 3, simply click on both the wireless and Bluetooth icons on the Pi and choose ‘Turn off Wi-fi’ and ‘Turn off Bluetooth’, respective­ly. Keep your Pi connected to a monitor and keyboard, as you’ll need this for sending payments later. Once you’re offline, run the command electrum in Terminal to start the wallet.

3 GENERATE WALLET SEED

Choose ‘Auto Connect’ on the first Electrum window, then click ‘Next’. On the next screen choose a ‘standard’ wallet and ‘Create a New Seed’. Electrum generates 12 random words for wallet seed and do as the program requests and write these down on paper. These random words will enable you to restore your wallet if anything happens to your Pi. Click ‘Next’ to continue.

4 CONFIRM AND STORE WALLET SEED

Use the words you wrote down earlier to retype your wallet seed. Remember that in the wrong hands, the seed can be used to steal from you, so store the paper in a safe place or, better yet, memorise the words. Try using the Loci method to memorise the words by associatin­g them with places in a familiar location such as your home.

5 CHOOSE YOUR WALLET KEY PASSWORD

After confirming the wallet seed you can optionally set a password to protect this copy of the wallet on the Pi. You’ll need to re-enter this password when sending Bitcoins. Ideally choose a password that’s at least 10 characters long with a mixture of letters, numbers and symbols. Electrum alerts you if a password is weak, moderate or strong. Do not use any of the words in your wallet seed for the password.

6 EXPORT MASTER PUBLIC KEYS

In the Electrum Wallet, click the ‘Wallet’ menu option then ‘Master Public Keys’. This will generate a string of text that you’ll use on a separate computer for your ‘watching wallet’ so you can receive payments.

Click the blue icon to copy the key then go to Applicatio­ns > Accessorie­s > Text Editor to paste it into a text file. Insert a USB stick and save the new text file to it.

7 INSTALL WATCHING WALLET

Safely eject the USB stick from the Pi and insert the stick into the computer that you want to use for your ‘Watching Wallet’. Electrum works on most platforms but for security reasons, and because we’d always recommend GNU/Linux over any other platform, place your watching wallet on a spare Linux system, if possible.

If you’re using a Debian-based distro like Ubuntu, repeat Step 1 but make sure that you install python-pip as well as python-qt4. For other platforms follow the instructio­ns at electrum. org/#download.

8 RESTORE MASTER KEYS

Launch the Electrum client on your online machine. In Linux, you can simply run electrum from the Terminal. Choose ‘Auto Connect’ once again on the first screen and click ‘Next’. Click on the ‘standard wallet’ option once again and then on the ‘Keystore’ screen choose ‘From Public or Private Keys’. On the next screen, paste in the master key in the text file from your USB stick. Read the warning and click ‘OK’.

9 SET UP ADDRESSES

Electrum will now generate addresses for you and when the main window opens click on the ‘Receive’ tab to view your address. You’ll see both a text string and a handy QR code for your new address. Type a descriptio­n for your receiving address if you wish, then click ‘Save’. You can generate more addresses later.

10 TEST WALLET ADDRESS

Using your current Bitcoin wallet, try to send some funds to your new wallet address. If possible, use a client which supports scanning QR codes, so there’s no danger of getting the address wrong.

Once the payment is sent, the unconfirme­d new balance should show in the bottom-left corner of the Electrum Window. Now, you’ll need to wait until the balance is confirmed before proceeding.

11 SET UP SENDING

Now that you can receive funds, it is time to test if you can send them. Find your recipient’s wallet address. For this tutorial, we are using the Bitcoin Address of the Electronic Frontier Foundation (EFF) to send a donation.

Click on the ‘Send’ tab in Electrum and paste the address into the ‘Pay to’

 ??  ??
 ??  ??
 ??  ??
 ??  ??

Newspapers in English

Newspapers from Australia