Chapter 6

Establishing an Ethereum Wallet

IN THIS CHAPTER

Bullet Learning what an Ethereum wallet is

Bullet Comparing Ethereum wallets

Bullet Choosing the best type of Ethereum wallet

Bullet Installing the MetaMask Ethereum wallet

When most people think of wallets, they think of folded leather cases for storing money, credit cards, identification, and even pictures. An Ethereum wallet is pretty much the same thing, except it stores the ways to access your valuable stuff on the Ethereum blockchain and can be either a physical or a virtual item.

In the blockchain world, you have to present private keys to access virtual currency and data. An Ethereum wallet holds the keys that allows you to access your content on the Ethereum blockchain. Simply put, an Ethereum wallet securely stores your private encryption keys.

Regardless what you’re planning to do with Ethereum, you need a way to find and access data in blocks. That’s where a wallet comes in. It stores your private keys, which allow you to buy and sell crypto-assets and to interact with smart contracts. Without a wallet, you wouldn’t be able do anything other than just look at Ethereum blockchain blocks.

In this chapter, you discover the different types of Ethereum wallets and look at popular wallet options so you can select the best wallet for your needs.

Unlocking the Secrets of an Ethereum Wallet

Everything stored in an Ethereum block has an address so that the owner can find and access their data in blocks. Data stored in Ethereum blocks can be crypto-assets, such as ether or other tokens, smart contracts, or any other data. The address of the data identifies the owner of that data. And when it comes to crypto-assets, only the owner can access that data. Well, anyone could access encrypted data, but only the owner can decrypt the data and consume the asset. For more on crypto-assets, see Chapters 3 and 4.

The person who controls the private key used to encrypt data on the blockchain controls the data. The only way that you can claim any crypto-asset is to prove that you control the private key associated with a crypto-asset’s address.

Technical stuff You learn about hashes, keys, and Ethereum’s Keccak-256 algorithm in Chapter 2. Addresses in Ethereum are the last (rightmost) 20 bytes of the hash of the owner’s public key. To calculate an address, just calculate the Keccak-256 hash of a public key, and then copy the rightmost 20 bytes. The resulting value is the address for that account’s public key. The code to calculate an address from a public key looks like this:

addr = right(keccak256(pubkey),20)

The only way to protect your crypto-assets is to protect your private keys. You need some mechanism to store your private key so that you can get to it, but no one else can. The primary function of a wallet is as a place to store one or more private keys used to access blockchain data.

The perfect wallet makes it really easy for you to get to your keys and impossible for anyone else to access your keys. All wallets balance these two goals and strike some compromise between utility (how easy it is to access your keys) and security (how safe your keys are from attack).

Examining the Types of Ethereum Wallets

Private keys can be stored in several ways, ranging from very secure to very easy to access. You should consider how important your private keys are and select a wallet type that works for you. The main categories of wallets follow:

  • Software wallets store private keys in data files, where users can easily access them.
  • Hardware wallet store private keys on a physical chip stored inside a device, such as a Ledger Nano S.
  • Paper wallets are pieces of paper with the keys printed on them.

Sorting out software wallets

Software wallets are programs that store private keys and make it easy for users to retrieve and use those keys. After setting up your wallet, you can access your keys by providing a user ID and password or an encrypted file that only you have. Software wallets can be further divided into two main categories: hot wallets and cold wallets.

Hot wallet

A hot wallet is one that stores your keys online. You can easily access your keys, and your Ethereum assets, from anywhere in the world. All you need is an Internet connection and access credentials. Although hot wallets are convenient, that convenience comes at a cost. If someone steals your access credentials, he or she can steal your Ethereum assets.

Also, you have to trust the wallet organization that stores your keys. If your wallet organization is hacked or goes out of business, you could lose everything. If that organization is a target of an investigation, your information could be divulged or your Ethereum assets could be frozen. You give up control to get convenience.

Cold wallet

A cold wallet is one in which you store your keys offline. You need to provide your keys only when you want to access your Ethereum assets. You can store keys offline in multiple ways, but this approach requires a few extra steps when you want to buy or sell crypto-assets or interact with smart contracts.

Although cold wallets are a little less convenient, they can be more secure. You have control over your keys with a cold wallet and can take whatever precautions you feel are necessary to protect your keys. Using a cold wallet gives you an alternative and mitigates the threat of an attacker hacking into your online wallet and harvesting lots of keys.

Warning With a cold wallet, you're responsible for protecting your keys. You have to make sure that every place you store your keys is as secure as possible. If you have a lot of value stored on the Ethereum blockchain, make sure that your key storage locations are as secure as possible and can’t be accessed by anyone but you.

Choosing between hot and cold wallets

How do you decide whether to use a hot wallet or a cold wallet? If you want more convenience and trust the security of an online wallet vendor, a hot wallet might be the best choice. Also, if you don’t plan to store anything of great value using a specific Ethereum account, a hot wallet is easiest and may make the most sense for that account.

On the other hand, if you distrust online vendors and are comfortable taking responsibility for securing your key storage, a cold wallet will give you more control. Or if you plan to store assets with substantial value, you should take responsibility for protecting your own stuff. You will have to sacrifice some convenience, but losing all your cryptocurrency is inconvenient itself.

Types of wallet client software

After you decide to store your keys in a hot or cold wallet, your next choice is the type(s) of wallet client software. If you choose an Ethereum software wallet to store your keys, you need to run that software somewhere. You have several choices:

  • Web wallets: Wallet software that you access by using a web browser.
  • Desktop wallets: Software that runs on a desktop or laptop computer. In most cases, desktop wallets run on computers running Microsoft Windows, macOS, or Linux.
  • Mobile wallets: Ethereum wallets for mobile devices. The most common wallet software runs on the iOS and Android operating systems for smartphones and tablets.

Tip You don’t have to choose just one type of Ethereum wallet. You can use multiple wallets, depending on your needs. Keys for high-value crypto-assets need to be protected more carefully, whereas keys for low-value crypto-assets could be stored online for easier access.

Handling hardware wallets

An Ethereum wallet option that is more secure than most software wallets is a hardware wallet. A hardware wallet stores private keys on a physical chip. You can connect the device housing the chip to many different types of computers and mobile devices, thus providing multiple ways to access the keys. Most hardware wallets also provide physical buttons to manage access to your keys.

The advantage of a physical wallet is the increased security. You connect your device to a computer only when you want to access your blockchain assets. When the device is not connected, your keys are safe inside the physical device. An attacker would have to physically steal your wallet device and know your access credentials to get to your keys.

The disadvantage of a physical wallet is the loss of convenience and redundancy. You must attach your physical wallet to a computer or device every time you want to access your blockchain assets. If you access assets frequently, this process could become annoying. Also, if you lose your physical device, you may not ever be able to recover access to your blockchain assets. For that reason, many physical wallet users make at least one backup copy of their keys and take extra care to store the copies in a secure location.

Perusing paper wallets

The last type of wallet can be the most secure. As the name implies, a paper wallet is literally just a piece of paper. After creating an Ethereum account and generating keys, one way of storing those keys is by simply printing them on paper. Most key generation options give you the choice of printing your keys. If you choose that option, you’ll get a hard copy of the private and public keys, along with a QR code of each key. Figure 6-1 shows a paper wallet.

Digital capture of a paper Ethereum wallet with private and public keys, along with a QR code.

FIGURE 6-1: A paper Ethereum wallet.

Whenever you want to access your blockchain assets, such as to buy or sell Ether, you can either type in your private key or scan the QR code. Of course, the software that you’re using to access Ethereum has to support QR scanning.

Warning Paper wallets are secure only if you keep your paper secret. Carefully guard that piece of paper. Anyone who can grab the paper, or even take a picture of it, can steal all of your Ethereum assets. And, just like with hardware wallets, it's a good idea to make a backup copy and keep it in a secure location.

Choosing an Ethereum Wallet

You have many choices for Ethereum wallets, and in this section, you learn about the most popular types. You can use this information to decide which wallet will best fit your needs.

If, after reading this section, you aren’t sure which one is the best wallet, don’t worry — choose the one that looks good and start using it. If you decide later to change to another wallet, the process is easy. And no rule dictates that you can’t have multiple Ethereum wallets. (It’s not like cramming multiple wallets into your back pocket!)

Software wallets

As mentioned, software wallets are simply programs that generate, store, and manage your keys Your options are web wallets, desktop wallets, and mobile wallets. The two primary differences among software wallet options are where they run and where they store your keys.

Web wallets

Web wallets are popular for casual Ethereum use. They are easy to use and make access to your keys convenient. To open your wallet, you need only an Internet connection, a web browser, and your login credentials. Table 6-1 lists popular web wallets.

TABLE 6-1 Popular Web Wallets

Name

Description

Pros

Cons

MyEtherWallet, www.myetherwallet.com

Open-source, decentralized cold wallet. You locally control your keys.

Most popular Ethereum web wallet. Works well with hardware wallets.

Has been hacked and may be vulnerable to phishing attacks.

Coinbase, www.coinbase.com

Popular cryptocurrency exchange that provides a hot wallet as well.

Provides more than just wallet services. Long history handling cryptocurrency.

Limited tokens and coins supported. Keys stored online.

Guarda, https://guarda.co

Cold wallet that supports multiple cryptocurrencies and makes it easy to transfer funds between cryptocurrencies. Also offers a desktop wallet.

One of the first to support multiple types of coins and tokens. Doesn't store personal info.

User must manage local key storage.

Desktop wallets

Desktop wallets are software programs that run on a personal computer. Most desktop wallets store keys locally, so you need to have access to your computer to open your wallet. Table 6-2 lists popular desktop wallets.

TABLE 6-2 Popular Desktop Wallets

Name

Description

Pros

Cons

Exodus, www.exodus.io

First to offer multiple cryptocurrencies in a single wallet. Cold wallet with easy key backup and restore operations.

Visually appealing and informative, easy-to-use interface.

Source code is not open source.

Mist, https://sourceforge.net/projects/ethereum-wallet.mirror

Cold wallet and the official Ethereum wallet, developed by those who created Ethereum.

Created by the Ethereum Foundation, officially endorsed wallet.

Less user friendly than other wallets.

MetaMask, https://metamask.io/

Cold wallet running as a Firefox or Chrome extension. Supports easy switching between test and live Ethereum networks.

Partially funded by the Ethereum Foundation, easy to use in Chrome. Easy to switch between test and live networks.

Released only as a Chrome extension, making it possible for other websites to see that you have a wallet installed.

Mobile wallets

Mobile wallets are similar to desktop wallets, but the software runs on mobile devices. Your keys are commonly stored on the mobile device as well. A mobile wallet is a good option if you always want your keys with you. The drawback is that if you lose your mobile device, you could lose access to your Ethereum assets. (That’s why backups are always good.) Table 6-3 lists popular mobile wallets.

TABLE 6-3 Popular Mobile Wallets

Name

Description

Pros

Cons

Jaxx, https://jaxx.io/

Cold wallet available on mobile devices and desktops (Windows, macOS, Linux).

Multi-platform support. Stores keys on specified device.

Code is not open source. Limited number of coins and tokens supported.

Coinomi, www.coinomi.com

Cold wallet for multiple cryptocurrencies currently available for only Android mobile devices.

Runs on Android, iOS, and desktops. Extensive list of supported coins and tokens. Focus on privacy.

Code is not open source.

Bread (BRD), https://brd.com/

Cold wallet for multiple cryptocurrencies that runs on iOS and Android mobile devices.

No central server. Easy to use and fast. Code is open source.

Limited number of supported coins and tokens. No two-factor authentication.

Hardware wallets

Hardware wallets provide an extra layer of security for your keys because they are stored on a physical chip inside the device. Most hardware wallets are USB devices. You access your keys by attaching the wallet device to a computer or a mobile device, and then running some software to access the keys. Depending on the device, the software could be web based or running locally on the computer or mobile device. Several software wallets provide the option to integrate with hardware wallets to make key storage even more secure.

Storing your keys on your own device means that you have to take measures to secure the device. Always be aware of the device’s location and always have a backup in case the device goes missing. Table 6-4 lists popular hardware wallets.

TABLE 6-4 Popular Hardware Wallets

Name

Description

Pros

Cons

Ledger Nano S, www.ledger.com/products/ledger-nano-s

Secure physical device that supports multiple cryptocurrencies and uses two-factor authentication.

Small. Most popular hardware wallet. Hardware designed for security. Supports over 700 types of coins and tokens.

Cost ($59). Requires client software to control crypto-assets.

Trezor, https://trezor.io/

Secure physical device that supports multiple cryptocurrencies and uses two-factor authentication.

Established reputation. Physical buttons or touchscreen. Supports nearly 700 types of coins and tokens.

Cost ($49). Requires a web wallet to control some stored crypto-assets.

KeepKey, www.keepkey.com

Similar to the Ledger Nano S and Trezor features, but with a slightly larger screen.

Firmware is open source. Designed to meet current blockchain requirements.

Cost ($49). Relative newcomer. Limited number of supported coins and token types. Requires Chrome add-in.

Paper wallets

A paper wallet is the simplest type of wallet. After you create an account and generate your keys, you simply print the keys on a plain piece of paper. Your keys exist only on the paper you used to print them; you don’t store them using software or on a hardware device.

The advantage to a paper wallet is that you have supreme control over your keys and no one else can touch them. That’s the biggest drawback, too. You have to take extra precautions to securely store a backup copy in case something happens to your piece of paper. Table 6-5 lists popular paper wallets.

TABLE 6-5 Popular Hardware Wallets

Name

Description

Pros

Cons

ETHAddress, https://github.com/ryepdx/ethaddress.org

Open-source project with source code you can compile and run on your own computer to generate private and public keys.

Open-source code. Useful for creating multiple accounts and keys.

No easy to use interface. Must download and run code or use Chrome add-in.

MyEtherWallet, www.myetherwallet.com

Provides the option to print your keys instead of storing them. The easiest way to create your own paper wallet.

Easy-to-use web interface for creating accounts and keys.

You must protect generated keys.

Installing MetaMask, an Ethereum Wallet

The preceding section shows you lots of options for Ethereum wallets. In this section, I show you how to set up a MetaMask wallet. You could use any other option, but MetaMask is a popular wallet that provides some nice ease-of-use options for developing blockchain apps.

MetaMask is a desktop wallet that runs as an extension to the Chrome, Firefox, Opera, or Brave web browsers. For these installation steps, I use the Chrome browser.

To install MetaMask, follow these steps:

  1. Launch your browser and navigate to https://metamask.io/.

    Your web browser will look like Figure 6-2.

  2. On the MetaMask page, click or tap Get Chrome Extension.

    If you’re using another browser, select the link to get MetaMask for your browser.

  3. Click or tap the Add to Chrome button and confirm your choice.
  4. After MetaMask installs, click or tap the MetaMask icon, and accept the license agreements.

    The MetaMask icon is the fox in the upper-right corner of your web browser

  5. In the MetaMask Create Account window, shown in Figure 6-3, enter a secure password. Click or tap Create.

    A screen appears where you can choose from several networks.

  6. From the network drop-down list, select Ropsten Test Network.

    MetaMask makes it easy to interact with both test networks to develop and test your apps, and live networks when you’re ready to deploy. Figure 6-4 show a list of the networks MetaMask supports.

Screen capture of MetaMask website with Brings Ethereum to your Browser message.

FIGURE 6-2: The MetaMask website.

Screen capture of MetaMask Create Account window with network and password selection options.

FIGURE 6-3: The MetaMask Create Account window.

Screen capture of MetaMask window with a dropdown list of MetaMask list of supported networks.

FIGURE 6-4: The MetaMask list of supported networks.

You've installed the MetaMask Ethereum wallet. MetaMask automatically creates an account named Account 1. You can see the private key and QR code for your new account by clicking or tapping the menu icon and then the Show QR Code option.

You can’t do very much with your wallet just yet, but in Chapter 7 you find out how to add ether to your account to fuel your blockchain activities.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset