Author

Topic: Messy Private Keys Dump (Read 400 times)

legendary
Activity: 3682
Merit: 1580
August 12, 2019, 02:01:55 PM
#11
BIP32 and BIP44 define the standard to derive private keys for different 'accounts' or coins. Following the standardization you will be able to derive your needed keys using your xpriv.

Bitcoin core doesn't use bip44.

I get that it wouldn't include the imported keys, but if the software can't figure out those other details from the xpriv then how can it be used to. migrate to another wallet today? Is it because the new wallet makes some educated guesses that are probably correct, but might not be, but you still have the old wallet software in that edge case?

Using an xpriv backup with the same wallet software i.e. bitcoin core is hard to do. So if it's hard to do it with the same software it's even harder with a different one. For example I know of no software that uses the same derivation path as bitcoin core.
legendary
Activity: 3472
Merit: 10611
August 11, 2019, 10:22:10 PM
#10
I get that it wouldn't include the imported keys, but if the software can't figure out those other details from the xpriv then how can it be used to. migrate to another wallet today? Is it because the new wallet makes some educated guesses that are probably correct, but might not be, but you still have the old wallet software in that edge case?

It is because there are standards on how to derive private keys (i.e. which derivation path to use for which address type).
This data is stored in wallet files. The xpriv itself is only used to derive the private keys.

BIP32 and BIP44 define the standard to derive private keys for different 'accounts' or coins. Following the standardization you will be able to derive your needed keys using your xpriv.

actually BIPs aren't exactly "standards", they are more like suggestions which is why most wallets are not compatible with each other specially when it comes to BIP39 (mnemonic) and also choice of paths for BIP32.
so it is best, when you make a backup, you also write down the wallet name you used, the version of the wallet you used to create the data you are backing up and possibly if you knew anything more about their derivation paths or at least your address(es).
hero member
Activity: 1778
Merit: 764
www.V.systems
August 11, 2019, 03:00:48 PM
#9
I've worked with masternode coins and in most of them you could just point to the dump file location and it parses the information on its own in the console.
So maybe mention where exactly you are trying to import and maybe you could get better responses here that way.
legendary
Activity: 1624
Merit: 2481
August 11, 2019, 06:55:57 AM
#8
I get that it wouldn't include the imported keys, but if the software can't figure out those other details from the xpriv then how can it be used to. migrate to another wallet today? Is it because the new wallet makes some educated guesses that are probably correct, but might not be, but you still have the old wallet software in that edge case?

It is because there are standards on how to derive private keys (i.e. which derivation path to use for which address type).
This data is stored in wallet files. The xpriv itself is only used to derive the private keys.

BIP32 and BIP44 define the standard to derive private keys for different 'accounts' or coins. Following the standardization you will be able to derive your needed keys using your xpriv.
newbie
Activity: 2
Merit: 0
August 10, 2019, 03:16:17 PM
#7
I get that it wouldn't include the imported keys, but if the software can't figure out those other details from the xpriv then how can it be used to. migrate to another wallet today? Is it because the new wallet makes some educated guesses that are probably correct, but might not be, but you still have the old wallet software in that edge case?

legendary
Activity: 3682
Merit: 1580
August 09, 2019, 01:31:46 PM
#6
- If you're looking to import the private keys into different wallet software NOW then is what you want to import/sweep. You can ignore the rest.

- If you're looking to save this dump file for import years later then just don't. Instead use the backup wallet file option in the file menu of bitcoin core.

Why not just backup the "extended private masterkey" for use years later? It would certainly be easier to write it down on paper or metal than each individual private key (assuming you are using many private keys from the same extended private masterkey so to break up your balance for privacy)?

Is it because you can't currently import it into bitcoin core and might need to use another app? It seems that this would give you all the benefits of bip39 without the downsides.

The xprv doesn't include all the information you need to restore the wallet. It doesn't tell you what derivation path was used or what script types were used i.e. whether you created p2pkh, p2wpkh etc. addresses. It doesn't tell you how many addresses you generated. And if you used addresses from imported private keys or pre-HD bitcoin core then those private keys can't be restored using the xprv.
newbie
Activity: 2
Merit: 0
August 09, 2019, 12:15:26 PM
#5
- If you're looking to import the private keys into different wallet software NOW then is what you want to import/sweep. You can ignore the rest.

- If you're looking to save this dump file for import years later then just don't. Instead use the backup wallet file option in the file menu of bitcoin core.

Why not just backup the "extended private masterkey" for use years later? It would certainly be easier to write it down on paper or metal than each individual private key (assuming you are using many private keys from the same extended private masterkey so to break up your balance for privacy)?

Is it because you can't currently import it into bitcoin core and might need to use another app? It seems that this would give you all the benefits of bip39 without the downsides.
hero member
Activity: 1232
Merit: 738
Mixing reinvented for your privacy | chipmixer.com
October 13, 2018, 07:05:07 AM
#4
Please help to understand all this messy thing.
that's why it's called wallet dump Cheesy
basically each line represents info of a specific bitcoin address
legendary
Activity: 3682
Merit: 1580
October 12, 2018, 11:36:56 AM
#3
- If you're looking to import the private keys into different wallet software NOW then is what you want to import/sweep. You can ignore the rest.

- If you're looking to save this dump file for import years later then just don't. Instead use the backup wallet file option in the file menu of bitcoin core.
legendary
Activity: 1946
Merit: 1427
October 11, 2018, 01:24:49 PM
#2
I don't think you're able to derive adresses in Bitcoin core itself from an (outside) XPRIV key. You'll need to use another library to do so.

See:
https://bitcoin.stackexchange.com/questions/52384/how-to-restore-bitcoin-core-hd-wallet-private-keys-by-master-key

Which lists this as a tool to do so; https://github.com/prusnak/bip32utils, but this tool is no longer available or has since moved. This should work aswell? https://iancoleman.io/bip39/
(https://github.com/iancoleman/bip39) (Always make sure you're running this safely!)

I haven't exactly tried it so i could be wrong.


You can then obviously import all your private keys generated with such a tool using

Code:
importprivkey

A more detailed guide can be found here:
https://bitcoin.stackexchange.com/questions/5941/how-do-i-import-a-private-key-into-bitcoin-core

Quote
2018-04-26T17:08:10Z change=1 # addr= hdkeypath=m/0'/0'/699'
2018-04-26T17:08:10Z change=1 # addr= hdkeypath=m/0'/1'/947'
2018-04-26T17:08:10Z change=1 # addr= hdkeypath=m/0'/0'/86

The should be importable, (as i presume this is a "change" adress.) Try using above method to import these and see if it works.

I'm not exactly an expert on Bitcoin Core, but the

Quote
0 script=1 # addr=
Doesn't seem right, and is not something i've seen before.
newbie
Activity: 18
Merit: 0
October 11, 2018, 12:57:17 PM
#1
Hi there,

Could anyone explain me how to export and import bitcoin's private keys in bitcoin core. I have exported private keys, it's a text file and have something like:

# Wallet dump created by Bitcoin v0.16.0
# * Created on 2018-10-08T10:01:00Z
# * Best block at time of backup was 544879 (00000000000000000010c6fe1edd3f236745b6af51929969bdaba2d59200dcc5),
#   mined on 2018-10-08T09:51:59Z

 "# extended private masterkey: "
2018-04-26T17:08:10Z change=1 # addr= hdkeypath=m/0'/0'/699'
2018-04-26T17:08:10Z change=1 # addr= hdkeypath=m/0'/1'/947'
2018-04-26T17:08:10Z change=1 # addr= hdkeypath=m/0'/0'/86

This is a long list which goes on about four thosand lines. Then I see:

0 script=1 # addr=
0 script=1 # addr=

This goes till some eight thousand lines and the file end with # End of dump

Please help to understand all this messy thing.


Jump to: