Author

Topic: Electrum wallet -> Trust wallet (Read 232 times)

legendary
Activity: 2268
Merit: 18771
May 01, 2022, 03:23:34 AM
#12
With the iancoleman.io/bip39 script I was able to recreate Electrum wallet addresses with the zprv... key from Electrum console getmasterprivate() in the form's field "BIP32 Root Key", selected Derivation Path tab "BIP141" with m/0 for receive addresses or m/1 for change addresses in field "BIP32 Derivation Path" and P2WPKH in field "Script Semantics" for native segwit addresses.
Yes, this is correct. This takes the extended key from Electrum, which is already at m/0', and derives at /0/0 (or /1/0 for change) to reach the same addresses Electrum generates.

I want to test a recovery in some other suitable wallet, maybe Sparrow or some other that supports to import a x/y/zprv master private key.
This is where things get confusing, partly because of the terminology used and partly because of BIP39 and Electrum following different standard derivation paths. Technically speaking, master keys are the keys at m (or M for public keys). Any child key at a level below that which contains the chain code necessary for generation of further child keys is an extended key, but Electrum calls the extended keys at m/0' the master keys. Some BIP39 wallets will call the keys at m the master keys, while others will call the keys at m/84'/0'/0' (for segwit) the master keys. Importing a zprv derived at one level in to a wallet which treats it as from a different level can result in different addresses being generated.

Better to just stick with seed phrases. Tongue
hero member
Activity: 714
Merit: 1010
Crypto Swap Exchange
April 30, 2022, 07:32:56 PM
#11
Note that Electrum's derivation paths can be a little confusing. The master private key and master public key it gives you are not really the master keys at all, which would be at derivation path m, but rather the extended keys at the derivation path it displays in Wallet -> Information, which as you say for segwit Electrum wallets is m/0'. This means that if you are using these extended keys to try to generate the same addresses, then you only need to add on the usual /0/0 for change and index to obtain the first address at m/0/0, and not m/0'/0/0 as you would expect.
With the iancoleman.io/bip39 script I was able to recreate Electrum wallet addresses with the zprv... key from Electrum console getmasterprivate() in the form's field "BIP32 Root Key", selected Derivation Path tab "BIP141" with m/0 for receive addresses or m/1 for change addresses in field "BIP32 Derivation Path" and P2WPKH in field "Script Semantics" for native segwit addresses.

I want to test a recovery in some other suitable wallet, maybe Sparrow or some other that supports to import a x/y/zprv master private key. You're very right that the derivation path necessary for the Electrum getmasterprivate() key is a bit confusing.
legendary
Activity: 2268
Merit: 18771
April 30, 2022, 09:53:54 AM
#10
If yes, it should be possible to export the Master Private Key from an Electrum Wallet (which requires some awkward procedure: temporarily saving your Electrum wallet unencrypted and without a password; I couldn't find any UI option for that)
Go to the console and enter the following command: getmasterprivate()
It will prompt you for your password if you have one set, and then display your zprv.

and import that wallet anywhere with proper Derivation Path setting (standard native segwit Electrum wallet has usually a derivation path of m/0' )
Note that Electrum's derivation paths can be a little confusing. The master private key and master public key it gives you are not really the master keys at all, which would be at derivation path m, but rather the extended keys at the derivation path it displays in Wallet -> Information, which as you say for segwit Electrum wallets is m/0'. This means that if you are using these extended keys to try to generate the same addresses, then you only need to add on the usual /0/0 for change and index to obtain the first address at m/0/0, and not m/0'/0/0 as you would expect.
hero member
Activity: 714
Merit: 1010
Crypto Swap Exchange
April 29, 2022, 11:03:18 AM
#9
I don't recommend closed-source wallets like TrustWallet either, but in the end it's the user's decission which software wallet to trust and use.

As I haven't used TrustWallet ever: does it support importing a wallet via the Master Private Key (xprv..., yprv..., zprv...)? Hm, looks like it doesn't.
If yes, it should be possible to export the Master Private Key from an Electrum Wallet (which requires some awkward procedure: temporarily saving your Electrum wallet unencrypted and without a password; I couldn't find any UI option for that) and import that wallet anywhere with proper Derivation Path setting (standard native segwit Electrum wallet has usually a derivation path of m/0' ). "Anywhere" would be any trustworthy and "good" wallet which supports importing a HD wallet's Master Private Key.

Messing with a completely unencrypted Electrum wallet file, private keys and particularly with a wallet's Master Private Key has to be done on a secure computer, preferably from an airgapped and agnostic live Linux like TAILS. You should know and understand what you're doing as a Master Private Key exposes all past and future private keys of a wallet! I don't recommend this for newbies (brush up your knowledge e.g. on https://learnmeabitcoin.com).
legendary
Activity: 2618
Merit: 6452
Self-proclaimed Genius
March 09, 2022, 08:06:12 AM
#8
Please advise whether it is possible to export BIP39 mnemonics from Electrum

Denis
Is your goal to be able to simultaneously use the same wallet in Electrum and Trustwallet?
If so, you can do pooya's suggestion to do the "reverse".
If it's just to restore your Electrum wallet to Trustwallet, then sending the funds normally is the best option.

Anyway, the post that you replied to already has the answer to your question, language barrier perhaps?
Try the local boards: https://bitcointalk.org/index.php#5
legendary
Activity: 2380
Merit: 5213
March 09, 2022, 07:01:16 AM
#7
It looks like a BIP 39, it has the same word list, but if you try to use it as a BIP 39 seed will either not work, either return different addresses.
To add to NeuroticFish's reply:

If a seed phrase is generated by electrum 4.1.2 and versions older than that, there's 1/16 probability that it's a valid BIP39 seed phrase. Of course, it will generate different addresses if it's used as a BIP39 seed phrase.
If a seed phrase is genereted by electrum 4.1.3 and versions newer than that, it's impossible that it's a valid BIP39 seed phrase.
legendary
Activity: 3668
Merit: 6382
Looking for campaign manager? Contact icopress!
March 09, 2022, 05:28:05 AM
#6
Hello, thanks

Please advise whether it is possible to export BIP39 mnemonics from Electrum

Denis

As said, Electrum seed is not a standard BIP 39 seed, it's an Electrum seed. It looks like a BIP 39, it has the same word list, but if you try to use it as a BIP 39 seed will either not work, either return different addresses.

To obtain the Electrum seed, from what I know:

* On PC there's on bottom-right a greenish button for the seed.
* On Android you have to tap the wallet name on the center of the screen and from there "show seed". (source: a Reddit post)

However, it may be safer/better to simply create a new wallet with the new software, especially if it can create a pure BIP 39 seed, backup (and verify/restore!) that new seed, then transfer the funds to the new wallet, using a small enough fee (I usually recommend 1 sat/vByte and RBF on).
legendary
Activity: 3612
Merit: 5297
https://merel.mobi => buy facemasks with BTC/LTC
March 09, 2022, 05:23:13 AM
#5
Hello, thanks

Please advise whether it is possible to export BIP39 mnemonics from Electrum

Denis

No, you cannot create a wallet with an electrum seed, and afterwards export a bip39 seed.
copper member
Activity: 2
Merit: 0
March 09, 2022, 05:13:16 AM
#4
Hello, thanks

Please advise whether it is possible to export BIP39 mnemonics from Electrum

Denis


You should never share a wallet between multiple different software like Electrum and TrustWallet. Specially if one of them is closed source which TrustWallet is. In fact I'd advise not using closed source wallets at all.

Hello, please advise how to access electrum wallet using another BIP 39 wallet, like Trust wallet
Electrum is not a "BIP39 wallet" although it supports importing BIP39 mnemonics. In other words Electrum uses a different algorithm to generate the mnemonic (12 words) that can not be recognized by other wallets.

If you insist on using TrustWallet you should create a new (separate) wallet there and send your coins from Electrum to that new wallet with an on-chain transaction.
You could also do the reverse, meaning create a wallet in TrustWallet, fund it, then copy the BIP39 seed phrase there with its corresponding derivation path and enter it in Electrum to get the same wallet.
legendary
Activity: 2730
Merit: 7065
March 09, 2022, 03:46:20 AM
#3
The only other wallet that supports Electrum seeds is the Blue Wallet. A native Electrum seed can be imported into Blue Wallet but only if the Electrum wallet was funded in the past. If the wallet is brand-new or empty, importing the seed into Blue Wallet won't work.

Can you tell us why you want to do that in the first place?
Is there a reason you can't use Electrum any longer?
legendary
Activity: 3472
Merit: 10611
March 09, 2022, 01:22:42 AM
#2
You should never share a wallet between multiple different software like Electrum and TrustWallet. Specially if one of them is closed source which TrustWallet is. In fact I'd advise not using closed source wallets at all.

Hello, please advise how to access electrum wallet using another BIP 39 wallet, like Trust wallet
Electrum is not a "BIP39 wallet" although it supports importing BIP39 mnemonics. In other words Electrum uses a different algorithm to generate the mnemonic (12 words) that can not be recognized by other wallets.

If you insist on using TrustWallet you should create a new (separate) wallet there and send your coins from Electrum to that new wallet with an on-chain transaction.
You could also do the reverse, meaning create a wallet in TrustWallet, fund it, then copy the BIP39 seed phrase there with its corresponding derivation path and enter it in Electrum to get the same wallet.
copper member
Activity: 2
Merit: 0
March 09, 2022, 12:46:05 AM
#1
Hello, please advise how to access electrum wallet using another BIP 39 wallet, like Trust wallet
Jump to: