Bitcoin Forum

Bitcoin => Electrum => Topic started by: GalNorm on July 04, 2018, 01:37:20 AM



Title: Thinking of switching to Electrum
Post by: GalNorm on July 04, 2018, 01:37:20 AM
So I want to start using Electrum. Do I use it to access my Armory wallet or do I have to create a new wallet with Electrum and make a transaction from Armory to it?

Also, if I (for some reason) lost my wallet but know the password, could I retrieve it or would it be gone? I noticed the app creates a file that stores the wallet locally. So, if that file is gone forever does it mean my satoshis are gone forever too, or is there a way to get my satoshis back in case that file went missing?


Title: Re: Thinking of switching to Electrum
Post by: pooya87 on July 04, 2018, 03:58:44 AM
So I want to start using Electrum. Do I use it to access my Armory wallet or do I have to create a new wallet with Electrum and make a transaction from Armory to it?
even if you choose any other wallet it is always wiser to create a new wallet and then make a transaction to send your funds from the old wallet to the new one instead of importing the old one into the new one like importing your private keys.

Quote
Also, if I (for some reason) lost my wallet but know the password, could I retrieve it or would it be gone? I noticed the app creates a file that stores the wallet locally. So, if that file is gone forever does it mean my satoshis are gone forever too, or is there a way to get my satoshis back in case that file went missing?
Electrum is a Hierarchical Deterministic (HD) wallet which means it is using a master private key to generate all the keys in your wallet. this master key is shown to you in the form of a bunch of words known as "Seed". all you need to do for back up is to write down this Seed somewhere and keep it safe. later on if you wanted to recover your funds then you simply start Electrum and instead of creating a new wallet and generating a new Seed you give it your old Seed to recover from.


Title: Re: Thinking of switching to Electrum
Post by: bob123 on July 04, 2018, 12:34:28 PM
pooya87 basically answered your questions. But to add a small information regarding the second point:

So, if that file is gone forever does it mean my satoshis are gone forever too, or is there a way to get my satoshis back in case that file went missing?

The word seed you are prompted to backup can regenerate all of your private keys.
You can either reimport it into electrum or use any other tool to derive the private keys (e.g. https://iancoleman.io/bip39/ (https://iancoleman.io/bip39/)).

You might download the site and store it offline. Once electrum should not be available somehow, you still can regenerate all of your private keys and import them into any other wallet.
This way you are completely independent from any software-/server- provider.

A better option would be to use a hardware wallet (nano s) with electrum.
This way you will be using a BIP39 compatible seed (which does work in any other BIP39 compatible wallet (almost everyone)).
And your private keys will stay in a secured environment, which does negate most attack vectors.



Title: Re: Thinking of switching to Electrum
Post by: Abdussamad on July 04, 2018, 12:57:33 PM
pooya87 basically answered your questions. But to add a small information regarding the second point:

So, if that file is gone forever does it mean my satoshis are gone forever too, or is there a way to get my satoshis back in case that file went missing?

The word seed you are prompted to backup can regenerate all of your private keys.
You can either reimport it into electrum or use any other tool to derive the private keys (e.g. https://iancoleman.io/bip39/ (https://iancoleman.io/bip39/)).

You might download the site and store it offline. Once electrum should not be available somehow, you still can regenerate all of your private keys and import them into any other wallet.
This way you are completely independent from any software-/server- provider.

A better option would be to use a hardware wallet (nano s) with electrum.
This way you will be using a BIP39 compatible seed (which does work in any other BIP39 compatible wallet (almost everyone)).
And your private keys will stay in a secured environment, which does negate most attack vectors.



electrum seed is not bip39 so you can't use the coleman site to generate address specific private keys.

@OP You will have to create a new wallet file and send your coins there from armory. When creating the wallet make sure to write down your seed words on paper. As for backups here's a detailed article (https://bitcoinelectrum.com/how-to-backup-your-electrum-wallet/) about that.


Title: Re: Thinking of switching to Electrum
Post by: bob123 on July 04, 2018, 01:38:15 PM
electrum seed is not bip39 so you can't use the coleman site to generate address specific private keys.

Thats true. At least for the mnemonic seed phrase.

But since electrum does follow the BIP44 specification, the xpriv can be entered into the Account Extended Private Key field on https://iancoleman.io/bip39/ (https://iancoleman.io/bip39/) to restore the private keys.

So a backup of the mnemonic seed phrase AND the xpriv would be the best choice regarding safety.


Title: Re: Thinking of switching to Electrum
Post by: Abdussamad on July 04, 2018, 09:16:25 PM
electrum doesn't follow bip44 either. however you can grab the xpriv from the wallet file and use that in that tool. you'll have to adjust the derivation path though. why you would go through all this trouble idk. much better to not mess with private keys at all but if you absolutely must do so restore from seed in electrum and use that to export your private keys.


Title: Re: Thinking of switching to Electrum
Post by: HCP on July 06, 2018, 01:05:14 AM
So I want to start using Electrum. Do I use it to access my Armory wallet or do I have to create a new wallet with Electrum and make a transaction from Armory to it?
No. The wallet formats are incompatible. You'll either need to:
a. Export your private keys from Armory and import them into Electrum
b. Export your private keys from Armory and "sweep" them into Electrum
c. Send all your coins from Armory to Electrum

I would recommend C. (Note that b. is effectively the same thing as c. but more time consuming and complicated)


Quote
Also, if I (for some reason) lost my wallet but know the password, could I retrieve it or would it be gone? I noticed the app creates a file that stores the wallet locally. So, if that file is gone forever does it mean my satoshis are gone forever too, or is there a way to get my satoshis back in case that file went missing?
When you create a standard wallet in Electrum, it will give you a 12 word "seed mnemonic". This works in the same way as the "Root Key" paper backup does in Armory. It enables you to completely restore the wallet regardless of whether or not the file has been deleted, your computer exploded or you forgot the wallet password.




electrum seed is not bip39 so you can't use the coleman site to generate address specific private keys.
You can modify 2 lines of code in the iancoleman website and have it generate the keys from an Electrum seed mnemonic ;)





Title: Re: Thinking of switching to Electrum
Post by: pooya87 on July 06, 2018, 03:39:18 AM
electrum seed is not bip39 so you can't use the coleman site to generate address specific private keys.
You can modify 2 lines of code in the iancoleman website and have it generate the keys from an Electrum seed mnemonic ;)

if you are knowledgeable and willing enough to take the risk and start modifying code then why not just use Electrum code itself? you can go to its repository and just take the part where the Seeds and key generation stuff are and use it to generate your private keys.


Title: Re: Thinking of switching to Electrum
Post by: igor72 on July 07, 2018, 07:47:11 AM
electrum seed is not bip39 so you can't use the coleman site to generate address specific private keys.
You can modify 2 lines of code in the iancoleman website and have it generate the keys from an Electrum seed mnemonic ;)
Can you explain the modification in detail?


Title: Re: Thinking of switching to Electrum
Post by: HCP on July 09, 2018, 06:26:46 AM
You can modify 2 lines of code in the iancoleman website and have it generate the keys from an Electrum seed mnemonic ;)
Can you explain the modification in detail?

1. Search for this function (should be near Line ~104000):
Code:
self.check = function(mnemonic)

Change the last line from:
Code:
return h == nh;
to:
Code:
return true;


2. Search for this function (should be just under the one above):
Code:
self.toSeed = function(mnemonic, passphrase)

Change the following line from:
Code:
passphrase = "mnemonic" + passphrase;
to:
Code:
passphrase = "electrum" + passphrase;


NOTES:
- This will break the checksum functionality. The "return true;" modification basically makes it think ANY seed you type in is correct.
- To get it to generate the same addresses as Electrum:
1. Enter Electrum Seed
2. Click "BIP32" tab
3. Set "client" to "Custom Derivation Path"
4. Set "BIP32 Derivation Path" to: m/0 (to see "change" addresses, use m/1 )





Title: Re: Thinking of switching to Electrum
Post by: igor72 on July 09, 2018, 07:37:45 AM
Excellent!
Thank you so much!