Created
May 4, 2020 04:29
-
-
Save SomberNight/519014b2b66c177506c181ef90ce9415 to your computer and use it in GitHub Desktop.
Extract seed and xprv from Electrum wallet file from circa version 3.0
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import lib as electrum | |
Wallet = electrum.wallet.Wallet | |
WalletStorage = electrum.storage.WalletStorage | |
password = "1234" | |
storage = WalletStorage('/home/user/.electrum/testnet/wallets/this_should_be_the_path_to_your_wallet_file') | |
storage.decrypt(password) | |
wallet = Wallet(storage) | |
wallet.keystore.get_seed(password) | |
wallet.keystore.get_master_private_key(password) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Script here is specifically to be used with old Electrum, around version 3.0 as in description.
Note: use this script instead if you are getting the following error when opening your wallet file:
WalletFileException("Your wallet has an unsupported seed version: 14.\n\nTo open this wallet, try 'git checkout seed_v14'")
(that script is for modern Electrum)