Bitcoin Forum
June 20, 2024, 07:47:20 AM *
News: Voting for pizza day contest
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: To convert that 2fa wallet in standard wallet using the command line  (Read 77 times)
ANTONIOGARCIA84 (OP)
Newbie
*
Offline Offline

Activity: 1
Merit: 0


View Profile
June 19, 2024, 11:14:09 AM
 #1

Hi.

I want to restore seeds from 2 Bitcoin wallets (1 standard seed and 1 2fa seed) to 2 standard wallets for those 2 seeds from the command line:

1) Wallet standard:

electrum daemon -d

electrum --o restore ?

argument: word1 word2 word3 word4 word5 word6 word7 word8 word9 word10 word11 word12

{
    "msg": "This wallet was restored offline. It may contain more addresses than displayed. Start a daemon and use load_wallet to sync its history.",
    "path": "/home/user/.electrum/wallets/default_wallet"
}

electrum load_wallet


And with the wallet loaded I can already use it.

Here everything is OK.


2) Wallet 2fa:

electrum daemon -d

electrum --o restore ?

argument: word1 word2 word3 word4 word5 word6 word7 word8 word9 word10 word11 word12

Unexpected seed type '2fa'


I want to convert that 2fa wallet in standard wallet using the command line.

I guess in "electrum --o restore ?" you have to add some function to disable this 2fa wallet and convert it to standard wallet.

Does anyone know what function can be used?

Thanks for your time and for your answer.

All the best.
Findingnemo
Hero Member
*****
Offline Offline

Activity: 2366
Merit: 793


Bitcoin = Financial freedom


View Profile
June 19, 2024, 12:55:02 PM
Last edit: June 19, 2024, 05:38:00 PM by Findingnemo
 #2

You can't convert a 2FA wallet to a standard wallet or vice versa because both are different seed types that Electrum recognizes with its version number.



https://electrum.readthedocs.io/en/latest/seedphrase.html

But you can restore the 2FA wallet and export the private keys from the loaded wallet then import them into a new standard wallet.

As @hosseinimr93 pointed out, you can disable 2FA of your electrum but there is no way to convert multi-sig into single sig address type.



An easy reminder why you can't export a multisig key into a single key: a single key produces a different address format.

'Duly noted'  Smiley

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits.
..........UNLEASH..........
THE ULTIMATE
GAMING EXPERIENCE
DUELBITS
FANTASY
SPORTS
████▄▄█████▄▄
░▄████
███████████▄
▐███
███████████████▄
███
████████████████
███
████████████████▌
███
██████████████████
████████████████▀▀▀
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
.
▬▬
VS
▬▬
████▄▄▄█████▄▄▄
░▄████████████████▄
▐██████████████████▄
████████████████████
████████████████████▌
█████████████████████
███████████████████
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
/// PLAY FOR  FREE  ///
WIN FOR REAL
..PLAY NOW..
View ArchiveReport to moderator
hosseinimr93
Legendary
*
Offline Offline

Activity: 2436
Merit: 5397



View Profile
June 19, 2024, 01:44:35 PM
Merited by LoyceV (6), Findingnemo (1)
 #3

But you can restore the 2FA wallet and export the private keys from the loaded wallet then import them into a new standard wallet.
No, you can't.
Electrum 2FA wallet is a 2 of 3 multi-signature wallet and there are three private keys for each of addresses. There is no way to import your address with a single private key.


To OP:
If you want to disable 2FA, import the seed phrase of your 2FA wallet and choose to disable 2FA.
Take note that you don't make your wallet a standard wallet with disabling 2FA and your wallet will be still a multi-signature wallet. There is no way to turn a multi-signature wallet to single-signature wallet.

▄▄███████▄▄
▄██████████████▄
▄██████████████████▄
▄████▀▀▀▀███▀▀▀▀█████▄
▄█████████████▄█▀████▄
███████████▄███████████
██████████▄█▀███████████
██████████▀████████████
▀█████▄█▀█████████████▀
▀████▄▄▄▄███▄▄▄▄████▀
▀██████████████████▀
▀███████████████▀
▀▀███████▀▀
.
 MΞTAWIN  THE FIRST WEB3 CASINO   
.
.. PLAY NOW ..
DaveF
Legendary
*
Offline Offline

Activity: 3514
Merit: 6352


Crypto Swap Exchange


View Profile WWW
June 19, 2024, 02:09:14 PM
 #4

You can't do it from the command line as far as I can see.
You CAN do it from the GUI.

https://electrum.readthedocs.io/en/latest/2fa.html

Quote
Restoring from seed

Even if TrustedCoin is compromised or taken offline, your coins are secure as long as you still have the seed of your wallet. Your seed contains two master private keys in a 2-of-3 security scheme. In addition, the third master public key can be derived from your seed, ensuring that your wallet addresses can be restored. In order to restore your wallet from seed, select “wallet with two factor authentication”, as this tells Electrum to use this special variety of seed for restoring your wallet.

Don't know if you can do the GUI, but if you can't check the android phone version of electrum. I know you can restore the 2fa from there I don't know if it still requires trusted coin.

-Dave

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
hosseinimr93
Legendary
*
Offline Offline

Activity: 2436
Merit: 5397



View Profile
June 19, 2024, 02:20:34 PM
 #5

I know you can restore the 2fa from there I don't know if it still requires trusted coin.
Two of master private keys and all three master public keys can be derived from 2FA seed phrase.
Therefore, if you have access to your 2FA seed phrase, you have all the required keys for making transaction from your wallet and you don't rely on trustedcoin.

▄▄███████▄▄
▄██████████████▄
▄██████████████████▄
▄████▀▀▀▀███▀▀▀▀█████▄
▄█████████████▄█▀████▄
███████████▄███████████
██████████▄█▀███████████
██████████▀████████████
▀█████▄█▀█████████████▀
▀████▄▄▄▄███▄▄▄▄████▀
▀██████████████████▀
▀███████████████▀
▀▀███████▀▀
.
 MΞTAWIN  THE FIRST WEB3 CASINO   
.
.. PLAY NOW ..
Findingnemo
Hero Member
*****
Offline Offline

Activity: 2366
Merit: 793


Bitcoin = Financial freedom


View Profile
June 19, 2024, 03:38:30 PM
 #6

But you can restore the 2FA wallet and export the private keys from the loaded wallet then import them into a new standard wallet.
No, you can't.
Electrum 2FA wallet is a 2 of 3 multi-signature wallet and there are three private keys for each of addresses. There is no way to import your address with a single private key.


To OP:
If you want to disable 2FA, import the seed phrase of your 2FA wallet and choose to disable 2FA.
Take note that you don't make your wallet a standard wallet with disabling 2FA and your wallet will be still a multi-signature wallet. There is no way to turn a multi-signature wallet to single-signature wallet.

Hmm, thanks for correcting me.  Smiley

That is why I always hesitate to reply regarding the technical questions cause I kind of mess up some of the time even though I am spending more and more time learning about technical aspects, I guess it's really not my cup of tea. Sad

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits.
..........UNLEASH..........
THE ULTIMATE
GAMING EXPERIENCE
DUELBITS
FANTASY
SPORTS
████▄▄█████▄▄
░▄████
███████████▄
▐███
███████████████▄
███
████████████████
███
████████████████▌
███
██████████████████
████████████████▀▀▀
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
.
▬▬
VS
▬▬
████▄▄▄█████▄▄▄
░▄████████████████▄
▐██████████████████▄
████████████████████
████████████████████▌
█████████████████████
███████████████████
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
/// PLAY FOR  FREE  ///
WIN FOR REAL
..PLAY NOW..
View ArchiveReport to moderator
LoyceV
Legendary
*
Online Online

Activity: 3346
Merit: 16852


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
June 19, 2024, 05:06:35 PM
Merited by Findingnemo (1)
 #7

That is why I always hesitate to reply regarding the technical questions cause I kind of mess up some of the time
Now that you know you messed up, it's best to edit your post and strike through the incorrect part. Others may read it in the future.
An easy reminder why you can't export a multisig key into a single key: a single key produces a different address format.

nc50lc
Legendary
*
Offline Offline

Activity: 2450
Merit: 5723


Self-proclaimed Genius


View Profile
Today at 04:37:06 AM
 #8

I guess in "electrum --o restore ?" you have to add some function to disable this 2fa wallet and convert it to standard wallet.
I think you meant to just disable 2fa so you wont have to use the authenticator app,
not necessarily convert the wallet to standard since it's still a 2-of-3 MultiSig, 2fa enabled or not.

If so, that's still not possible in the command line since the only options for restore command are:
text (seed, master key, prvKeys or addresses), passphrase (extension), password, encrypt_file and wallet_path.
Ref: github.com/spesmilo/electrum/blob/master/electrum/commands.py#L281

In an additional note, they also prevent 2fa when creating a wallet in the command line.
e.g.: electrum --o create --seed_type "2fa"
result: Unexpected seed type '2fa'

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!