BitBox02 multisignature wallet
Tags: Security, Electrum, Hardware Wallet, Multisig, Bitcoin

BitBox02 ❤️ Electrum: part 3

This post explains how to use the best-in-class multisignature feature of the BitBox02 for multisig wallets with Electrum. The integrity of the whole multisig setup, including all co-signers, will be secured by the BitBox02 hardware wallet. We wrote this post for advanced users, so we’ll go a bit more into details.

Electrum

The free open-source Electrum wallet is a powerful Bitcoin light client for Windows, Mac and Linux. It connects to an Electrum server of your choice and offers many advanced features. It can be used as a pure software wallet, with the private keys stored on your computer, but it also works very well with most hardware wallets.

Note: Electrum wallet is a third-party application. We don’t have control over the development and distribution of the software and can’t provide any guarantees. The BitBox02, however, keeps your private keys safe at all times.

What is a multisignature wallet?

A multisignature Bitcoin wallet can be viewed as a shared account that needs multiple authorizations to spend money. The shared control is achieved by using more than one private key. The number of keys that need to sign a transaction (M), and the total number of keys (N) are defined when creating the wallet. The wallet is then typically referred to as a M-of-N multisig wallet, for example a “2-of-3 multisig wallet” where 2 keys out of a total of 3 need to sign each transaction.

Multisignature wallets have various applications:

Distribute responsibility : different people are controlling one key each, and every transaction needs to be signed by a predefined number of keys.

: different people are controlling one key each, and every transaction needs to be signed by a predefined number of keys. Added security : one person controls all keys, but these are created on different computers or hardware wallets, avoiding a single point-of-failure.

: one person controls all keys, but these are created on different computers or hardware wallets, avoiding a single point-of-failure. Added resilience: Multiple keys stored in different locations make the wallet more resilient against theft (e.g. one stolen key is not enough) and data loss (funds are still recoverable with a lost key).

Unfortunately, keys cannot simply be rotated, so with each change in signing keys (e.g. because an employee left the company, or a key has been compromised) a new wallet needs to be created, to which all funds are then transferred.

What are potential pitfalls?

Creating a multisignature wallet sounds like an easy enough solution, and is often advised. But due to more moving parts, such setups are complex and contain pitfalls not immediately obvious. In combination with hardware wallets, multisig wallets are especially hard to use securely, as most hardware wallets are stateless and don’t remember the other co-signers. Without that knowledge, it’s hard to independently verify receiving addresses or outgoing transactions.

Backup of multisig setups

Each participant in a multisignature setup must not only secure their private keys or seed, but also additional metadata like the extended public keys (xpub) of all co-signers, the used threshold, derivation path and script type.

Why is that? Even though a multisignature setup, for example a 2-of-3 multisig wallet, sounds like it could be recovered with two keys, it cannot. Funds are locked with the hash of all extended public keys and the threshold, so you need all of them to restore the wallet, and then the required amount of private keys to spend the funds.

Receiving funds

When creating and validating a new receiving address, your hardware wallet needs to let you independently verify the address and make sure that all co-signer parameters — like their xpub, total number and signing threshold — are correct. Otherwise, malware on your computer could trick you into receiving funds into a different wallet (partially) controlled by an attacker, for example by swapping out two co-signers in a 2-of-3 multisig wallet.

Spending funds

The tricky part for hardware wallets in signing multisig transactions is not the signature itself, but verifying that the change address is under sole control of the expected multisignature setup. This again depends on the knowledge of all xpubs of the co-signers.

Read more about this in our dedicated blog post The pitfalls of multisig when using hardware wallets.

How to do multisig properly?

The BitBox02 solves all these potential issues in the most thorough way: it lets you store the checksum of all relevant information about your co-signers directly in the hardware wallet. This enables the BitBox02 to automatically verify sending and receiving operations, which is not possible with other hardware wallets, like Ledger or Trezor. The only tricky part remains the backup, that we explain in detail further down.

Prepare your BitBox02s

We will use three BitBox02 hardware wallets for our multisignature setup. This is the recommended option, as it works the smoothest and avoids unnecessary complexity that could potentially lead to decreased security.

A multi-signature setup with hardware wallets of different manufacturers is also very interesting, but adds a lot of complexity, since other vendors miss some verification features. We will demonstrate how to do that securely in a follow-up article, with the BitBox02 adding significant security to the overall setup thanks to its unique capability to keep the co-signers in check.

Before you can use the BitBox02 with Electrum, you need to set up the devices and update them to firmware 9.0.0 (or higher) with the BitBoxApp.

In this multisig setup you need to know when to connect which device. It’s helpful to give each BitBox02 a device name, and additionally label it using the numbered stickers that come with every device.

You can name and update your devices in the BitBoxApp under “Manage device”.