<p>The benefit of hardware <a href="https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki" rel="nofollow noreferrer">deterministic</a> wallets is that your keys are permanently kept offline and secret, as long as you don't leak your seed words. To spend bitcoin, the transaction signing is performed on the device, keeping your keys safe.</p>

<p>If you encrypt the keys yourself (I'm assuming you're talking about bitcoin private keys, not an HD wallet seed), it depends how you store them. I can see three risks:</p>

<ol>
<li>If you're planning on storing them online and encrypt them all with the same passphrase, then you're reducing the security of your keys to the single passphrase. If you leak your passphrase, anybody with access to your data can decrypt and use your keys. If you don't store them online (including on a system with access to the internet) however, this is less of a risk.</li>
<li>Signing transactions. In order to sign transactions, you're going to have to decrypt your key and run it through some software. If you do this online, it's very risky. If you do it offline, you're still at risk of keyloggers and other malicious software that could be present on your machine. This also applies to when you generate your keys in the first instance.</li>
<li>Loss. If you lose your encrypted data or your passphrase, your bitcoin is lost. With an HD wallet, if you lose the wallet you can recover with the seed words. If you lose the seed words you can still use the wallet to transfer to an alternative address.</li>
</ol>

<p>If you do decide to use the passphrase method, note that there is already a <a href="https://github.com/bitcoin/bips/blob/master/bip-0038.mediawiki" rel="nofollow noreferrer">standard for protecting a private key with a passphrase</a> (<a href="https://www.bitaddress.org/" rel="nofollow noreferrer">example implementation</a> - check the paper wallet section), so it's not necessary to encrypt it separately yourself.</p>

CC BY-SA 3.0
2017-11-13T04:36:57.260Z
2017-11-13T05:06:16.750Z
2017-11-13T05:06:16.750Z
Adam Millerchip
<p>Generating keys on a computer that has never (and will never) connect to the internet is <strong>much</strong> more secure than generating keys on a computer that has (or will) connect to the internet. </p>

<p>Hardware wallets do not connect to the internet, ever. They interface with a computer, but through extremely restricted channels that ensure the part of the device that generates your keys remains isolated. </p>

<p>If you generate keys on a computer that is (or has been, or will be) connected to the internet, then you run the risk of some malware stealing your keys. This can be accomplished many ways, and the sort of encryption you put on the wallet becomes irrelevant. It doesn't matter how strong the encryption is, if a keylogger gets the password up front.</p>

<p>You can encrypt your hardware wallet's seed phrase if you'd like. That way if someone finds your seed phrase, they will not be able to steal your bitcoin unless they also have the password. But it also means you will have to store that password somewhere secure!</p>

CC BY-SA 3.0
2017-11-13T05:11:00.447Z
2017-11-13T05:11:00.447Z
chytrik
<p>If you wish, you can also encrypt your Electrum wallet seed with a third-party encryption software.  Just make sure you don't lose the password!</p>

CC BY-SA 3.0
2018-02-20T11:14:05.380Z
2018-02-20T11:14:05.380Z
Grzyx Woz
<p>No need to spend for a hardware wallet. You can do practically the same with Electrum. It's a stand-alone app that you can run on a USB stick or thumb drive. Just be sure to get the latest version. (Version 3.0.5) (they've patched some problems of the old version). Electrum is free and you can copy it on any ordinary USB drive and run it from there. </p>

<p>Electrum also generates wallet addresses using a single seed (group of words), so you can just print out the seed and keep it in your safe, or write it in a place where you know people won't just stumble across it accidentally. From the seed, you can regenerate your existing wallet addresses... and never lose your bitcoins.</p>

CC BY-SA 3.0
2018-02-20T11:11:46.050Z
2018-02-20T11:11:46.050Z
Grzyx Woz
<p>Hardware wallets are preferred to hot wallets and cold storage, as they cannot connect to the Internet, and do not require key input into a computer in order to sign transactions. The second point is important, but also partially wrong. The hardware wallet itself is a computer with very specific set tasks, mainly, key pair/seed generation and transaction signing. The keys are never supposed to leave the device and never were outside of the device, to begin with. You cannot input keys manually into a hardware wallet. They have their own random number generator hardware, which feeds into the CSPRNG, then the key/seed generator. This means, incidentally, that you do not need a "hardware wallet" to have a hardware wallet. An air-gapped computer put inside a dark room, with all the source code verified by hand, in a Faraday cage, and a whole lot of other security measures is also a hardware wallet. It's just much simpler to have a dedicated device engineered specifically for that purpose.</p>

<p>Online computers run the risk of the plaintext private key (or even the encrypted private key) being salvaged by malware. Once outside of a sandboxed and enclaved environment, always outside a sandboxed and enclaved environment.</p>

<p>The only attacks on hardware wallets require direct interfacing, proximity, or some zero-day that utilizes an infected user's computer to send commands to the wallet (e.g. load a custom firmware that makes key extraction possible). Direct interfacing requires that the hardware wallet is stolen, but will not necessarily output any keys/seeds, since ECDSA is resistant to chosen ciphertext attacks <a href="https://en.wikipedia.org/wiki/Elliptic_Curve_Digital_Signature_Algorithm#Security" rel="nofollow noreferrer">for the most part</a>. This would also require a zero-day to directly extract the keys. The proximity exploit would require access to the environment surrounding the key in order to influence the random generation, making the result more predictable and easier to attack (even this is a stretch, as they should have RF shielding). Given how limited these attacks are, unless a hardware wallet contains fortune, it's generally not worth an attacker's time to attack a hardware wallet from far away. It's much simpler for them to attack exchange wallets or hot wallets of normal users.</p>

<p>Note that none of these methods are secure against brute force. There is no way to stop brute force, it's just extremely inefficient. <a href="https://lbc.cryptoguru.org/trophies" rel="nofollow noreferrer">However, it has worked before.</a>. Brute force aside, an exchange wallet is the least secure, a hot wallet is still not secure, a hardware wallet is secure, and a cold storage wallet is impossible to attack electronically altogether.</p>

CC BY-SA 4.0
2019-03-25T03:34:40.943Z
2019-03-25T03:34:40.943Z
Expectator
<p>i am new to this community and like to know why one should prefer a hardware wallet instead of using encryption algorithm like AES-256 along with PKDF2 to secure crypto wallets ?
i currently hold btc in trezor wallet and planning to use AES to manually encrypt private keys by myself. 
I have been playing around with the crypto wallet encryptor,</p>

<p><a href="https://github.com/sufiyanghori1/crypto-wallet-encryptor" rel="nofollow noreferrer">https://github.com/sufiyanghori1/crypto-wallet-encryptor</a></p>

<p>which seems to be pretty effective.
it takes private key and a custom password as an input and encrypt it using AES-256.</p>

<p>i have read on various forums people using it but not sure if its any better than actual hardware wallet ?</p>

<wallet><encryption><wallet-security><hardware-wallet>
Encrypting wallet manually instead of using hardware wallet
satoshi_d
# Encrypting wallet manually instead of using hardware wallet

(Asked by: username_0 on 2017-11-13)

i am new to this community and like to know why one should prefer a hardware wallet instead of using encryption algorithm like AES-256 along with PKDF2 to secure crypto wallets ?
i currently hold btc in trezor wallet and planning to use AES to manually encrypt private keys by myself.
I have been playing around with the crypto wallet encryptor,

<https://github.com/sufiyanghori1/crypto-wallet-encryptor>

which seems to be pretty effective.
it takes private key and a custom password as an input and encrypt it using AES-256.

i have read on various forums people using it but not sure if its any better than actual hardware wallet ?

**Tags:** wallet, encryption, wallet-security, hardware-wallet


---

## 5 answers

### Answer by username_1 on 2017-11-13. Score: 3

The benefit of hardware [deterministic](https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki) wallets is that your keys are permanently kept offline and secret, as long as you don't leak your seed words. To spend bitcoin, the transaction signing is performed on the device, keeping your keys safe.

If you encrypt the keys yourself (I'm assuming you're talking about bitcoin private keys, not an HD wallet seed), it depends how you store them. I can see three risks:

1. If you're planning on storing them online and encrypt them all with the same passphrase, then you're reducing the security of your keys to the single passphrase. If you leak your passphrase, anybody with access to your data can decrypt and use your keys. If you don't store them online (including on a system with access to the internet) however, this is less of a risk.
2. Signing transactions. In order to sign transactions, you're going to have to decrypt your key and run it through some software. If you do this online, it's very risky. If you do it offline, you're still at risk of keyloggers and other malicious software that could be present on your machine. This also applies to when you generate your keys in the first instance.
3. Loss. If you lose your encrypted data or your passphrase, your bitcoin is lost. With an HD wallet, if you lose the wallet you can recover with the seed words. If you lose the seed words you can still use the wallet to transfer to an alternative address.

If you do decide to use the passphrase method, note that there is already a [standard for protecting a private key with a passphrase](https://github.com/bitcoin/bips/blob/master/bip-0038.mediawiki) ([example implementation](https://www.bitaddress.org/) - check the paper wallet section), so it's not necessary to encrypt it separately yourself.


---

### Answer by username_2 on 2017-11-13. Score: 2

Generating keys on a computer that has never (and will never) connect to the internet is **much** more secure than generating keys on a computer that has (or will) connect to the internet.

Hardware wallets do not connect to the internet, ever. They interface with a computer, but through extremely restricted channels that ensure the part of the device that generates your keys remains isolated.

If you generate keys on a computer that is (or has been, or will be) connected to the internet, then you run the risk of some malware stealing your keys. This can be accomplished many ways, and the sort of encryption you put on the wallet becomes irrelevant. It doesn't matter how strong the encryption is, if a keylogger gets the password up front.

You can encrypt your hardware wallet's seed phrase if you'd like. That way if someone finds your seed phrase, they will not be able to steal your bitcoin unless they also have the password. But it also means you will have to store that password somewhere secure!


---

### Answer by username_3 on 2018-02-20. Score: 1

If you wish, you can also encrypt your Electrum wallet seed with a third-party encryption software. Just make sure you don't lose the password!


---

### Answer by username_3 on 2018-02-20. Score: 1

No need to spend for a hardware wallet. You can do practically the same with Electrum. It's a stand-alone app that you can run on a USB stick or thumb drive. Just be sure to get the latest version. (Version 3.0.5) (they've patched some problems of the old version). Electrum is free and you can copy it on any ordinary USB drive and run it from there.

Electrum also generates wallet addresses using a single seed (group of words), so you can just print out the seed and keep it in your safe, or write it in a place where you know people won't just stumble across it accidentally. From the seed, you can regenerate your existing wallet addresses... and never lose your bitcoins.


---

### Answer by username_4 on 2019-03-25. Score: 0

Hardware wallets are preferred to hot wallets and cold storage, as they cannot connect to the Internet, and do not require key input into a computer in order to sign transactions. The second point is important, but also partially wrong. The hardware wallet itself is a computer with very specific set tasks, mainly, key pair/seed generation and transaction signing. The keys are never supposed to leave the device and never were outside of the device, to begin with. You cannot input keys manually into a hardware wallet. They have their own random number generator hardware, which feeds into the CSPRNG, then the key/seed generator. This means, incidentally, that you do not need a "hardware wallet" to have a hardware wallet. An air-gapped computer put inside a dark room, with all the source code verified by hand, in a Faraday cage, and a whole lot of other security measures is also a hardware wallet. It's just much simpler to have a dedicated device engineered specifically for that purpose.

Online computers run the risk of the plaintext private key (or even the encrypted private key) being salvaged by malware. Once outside of a sandboxed and enclaved environment, always outside a sandboxed and enclaved environment.

The only attacks on hardware wallets require direct interfacing, proximity, or some zero-day that utilizes an infected user's computer to send commands to the wallet (e.g. load a custom firmware that makes key extraction possible). Direct interfacing requires that the hardware wallet is stolen, but will not necessarily output any keys/seeds, since ECDSA is resistant to chosen ciphertext attacks [for the most part](https://en.wikipedia.org/wiki/Elliptic_Curve_Digital_Signature_Algorithm#Security). This would also require a zero-day to directly extract the keys. The proximity exploit would require access to the environment surrounding the key in order to influence the random generation, making the result more predictable and easier to attack (even this is a stretch, as they should have RF shielding). Given how limited these attacks are, unless a hardware wallet contains fortune, it's generally not worth an attacker's time to attack a hardware wallet from far away. It's much simpler for them to attack exchange wallets or hot wallets of normal users.

Note that none of these methods are secure against brute force. There is no way to stop brute force, it's just extremely inefficient. [However, it has worked before.](https://lbc.cryptoguru.org/trophies). Brute force aside, an exchange wallet is the least secure, a hot wallet is still not secure, a hardware wallet is secure, and a cold storage wallet is impossible to attack electronically altogether.


---

