Bitcoin Forum
November 11, 2024, 12:20:13 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 [2]  All
  Print  
Author Topic: (Help) I'm trying to get my private keys  (Read 466 times)
Cricktor
Legendary
*
Offline Offline

Activity: 938
Merit: 1460


Crypto Swap Exchange


View Profile
April 21, 2024, 11:57:42 PM
 #21

Thanks alot but is there is way for alot of adresses check and not (progrraming way )cause my device every time I'm trying There Is a something missing and overall not work

You could import the public addresses into a watch-only wallet in Electrum and you could quickly see if any of those addresses holds any funds. Electrum is a lightweight wallet and doesn't require to download the full or partial blockchain.

If you want to go this way, make sure you download Electrum solely from the official website https://electrum.org/ and verify properly your download file. I'm not going into detail for this as there's an excellent description for that in this forum.

When you have verified that you have funds in your addresses, you could import the private keys of your funded addresses or all private keys of your addresses in a spending wallet in Electrum.

█▀▀▀











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











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Sadderr (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
April 22, 2024, 12:32:54 AM
 #22

Thanks alot but is there is way for alot of adresses check and not (progrraming way )cause my device every time I'm trying There Is a something missing and overall not work

You could import the public addresses into a watch-only wallet in Electrum and you could quickly see if any of those addresses holds any funds. Electrum is a lightweight wallet and doesn't require to download the full or partial blockchain.

If you want to go this way, make sure you download Electrum solely from the official website https://electrum.org/ and verify properly your download file. I'm not going into detail for this as there's an excellent description for that in this forum.

When you have verified that you have funds in your addresses, you could import the private keys of your funded addresses or all private keys of your addresses in a spending wallet in Electrum.

Checked yesterday and It's empty
Cricktor
Legendary
*
Offline Offline

Activity: 938
Merit: 1460


Crypto Swap Exchange


View Profile
April 22, 2024, 02:49:50 AM
 #23

Based on your questions you had, I wouldn't place you in the experienced camp. What gives you confidence you did everything right? I ask because you don't give much details.

Are you sure you imported the correct address type (if you imported the private keys in Electrum)?

If you imported the public addresses and you expect to see some transaction history and there is none in Electrum, assuming it synced fully, then either you missed some public addresses or it is the wrong (empty) wallet you exported the addresses from. Based on your "Checked yesterday and It's empty" it could also be that your wallet has been emptied. It's guesswork.

█▀▀▀











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











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Sadderr (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
April 22, 2024, 11:05:26 AM
 #24

Based on your questions you had, I wouldn't place you in the experienced camp. What gives you confidence you did everything right? I ask because you don't give much details.

Are you sure you imported the correct address type (if you imported the private keys in Electrum)?

If you imported the public addresses and you expect to see some transaction history and there is none in Electrum, assuming it synced fully, then either you missed some public addresses or it is the wrong (empty) wallet you exported the addresses from. Based on your "Checked yesterday and It's empty" it could also be that your wallet has been emptied. It's guesswork.

Yes cause i have good knowledge  about crypto currencies  but I'm not experienced (good surface knowledge )

I haven't import them on electrum cause i have found a python script that work for checking the balance of accounts and I tried with all of the addresses and every account was 0
And I put some random adresses with balance(not mine) and the script found them 
So that what make me know that adresses all empty
nc50lc
Legendary
*
Offline Offline

Activity: 2590
Merit: 6366


Self-proclaimed Genius


View Profile
April 22, 2024, 11:49:20 AM
Merited by vapourminer (4), RickDeckard (4), Cricktor (2)
 #25

-snip-
And I'm  already have all the addresses of the wallet but they're alot and it will take very long time to check them individually
Are those addresses the result of the suggested dumpwallet command?

If so, you may have to specify which address type to dump because the command defaults to "bech32" if addresstype isn't explicitly set.
Since you do not know the actual address(es), you may have to create a separate dump with legacy and p2sh-SegWit addresses.

To do that, you either:
  • A. Close Bitcoin Core, set addresstype=legacy to your bitcoin.conf file, Open Bitcoin Core then use dumpwallet command;
        Close Bitcoin Core, set addresstype=p2sh-segwit, Open Bitcoin Core then use dumpwallet command with different dump file name.
        (Your third option would be addresstype=bech32 if your current dump file has legacy addresses; and the other type, bech32m isn't an option in 2020)

        Those two dump files will contain same private keys and amount of 'key & address lines' as your first dump file but will have the specified address type.
        Then use the script that you've mentioned above (after you share it so we can check if it's legit) to see if those addresses have bitcoins.

  • B. This wont require another two dump files;
        When you import to Electrum, specify the script types as noted in 'import private key' window's "info" tooltip button.
        Each WIF private key should be imported with different script types to restore all three address types.

    e.g. (imports legacy, p2sh-SegWit and Native SegWit addresses):
    WIF_Private_Key01
    p2wpkh-p2sh:WIF_Private_Key01
    p2wpkh:WIF_Private_Key01
    WIF_Private_Key02
    p2wpkh-p2sh:WIF_Private_Key02
    p2wpkh:WIF_Private_Key02
    WIF_Private_Key03
    p2wpkh-p2sh:WIF_Private_Key03
    p2wpkh:WIF_Private_Key03
    ...
    But, don't import too many in one wallet or Electrum may not sync.

█▀▀▀











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











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

Activity: 938
Merit: 1460


Crypto Swap Exchange


View Profile
April 22, 2024, 12:17:04 PM
Last edit: April 22, 2024, 12:31:27 PM by Cricktor
 #26

If so, you may have to specify which address type to dump because the command defaults to "bech32" if addresstype isn't explicitly set.
Since you do not know the actual address(es), you may have to create a separate dump with legacy and p2sh-SegWit addresses.

Holy moly, this is new to me, thanks for this! I just looked up the short help with bitcoin-cli help dumpwallet (Bitcoin Core v26.0) and there's absolutely no reference to addresstype whatsoever affecting the output of this command. I'm puzzled, need to investigate further.

When dumpwallet is affected by settings in bitcoin.conf like addresstype=legacy, it might be necessary to also specify changetype=legacy for change addresses (for legacy address type here).


I haven't import them on electrum cause i have found a python script that work for checking the balance of accounts and I tried with all of the addresses and every account was 0
And I put some random adresses with balance(not mine) and the script found them  
So that what make me know that adresses all empty

I'd rely at such an important verification step on proven tools like Electrum wallet. Your Python script may be OK, but how do you know after just a few tests? Your script may just skip gracefully without signaling issues if it's programmed the wrong way. If you don't understand the code, you can't know what it is doing. I would be careful with "unknown" scripts.

You don't give any details about the script and it's a bit annoying to always have to ask for further details. I mean, you should be the one who is very much interested to be certain to use the right tools, no?


What address type did you get in your output file of dumpwallet command (public addresses of 1... / 3... or bc1q...)?

█▀▀▀











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











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Sadderr (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
April 22, 2024, 12:24:53 PM
 #27

-snip-
And I'm  already have all the addresses of the wallet but they're alot and it will take very long time to check them individually
Are those addresses the result of the suggested dumpwallet command?

If so, you may have to specify which address type to dump because the command defaults to "bech32" if addresstype isn't explicitly set.
Since you do not know the actual address(es), you may have to create a separate dump with legacy and p2sh-SegWit addresses.

To do that, you either:
  • A. Close Bitcoin Core, set addresstype=legacy to your bitcoin.conf file, Open Bitcoin Core then use dumpwallet command;
        Close Bitcoin Core, set addresstype=p2sh-segwit, Open Bitcoin Core then use dumpwallet command with different dump file name.
        (Your third option would be addresstype=bech32 if your current dump file has legacy addresses; and the other type, bech32m isn't an option in 2020)

        Those two dump files will contain same private keys and amount of 'key & address lines' as your first dump file but will have the specified address type.

        Then use the script that you've mentioned above (after you share it so we can check if it's legit) to see if those addresses have bitcoins.

  • B. This wont require another two dump files;
        When you import to Electrum, specify the script types as noted in 'import private key' window's "info" tooltip button.
        Each WIF private key should be imported with different script types to restore all three address types.

    e.g. (imports legacy, p2sh-SegWit and Native SegWit addresses):
    WIF_Private_Key01
    p2wpkh-p2sh:WIF_Private_Key01
    p2wpkh:WIF_Private_Key01
    WIF_Private_Key02
    p2wpkh-p2sh:WIF_Private_Key02
    p2wpkh:WIF_Private_Key02
    WIF_Private_Key03
    p2wpkh-p2sh:WIF_Private_Key03
    p2wpkh:WIF_Private_Key03
    ...
    But, don't import too many in one wallet or Electrum may not sync.

I think it's gonna be useless because yesterday when I'm trying I used (getbalance) on btc core and it shows 0.000 I dont remember how many zeros but there wasn't another numbers

Also: on the first I tried to search for (name ) on wallet.dat file by notepad (normal one) and hxd (hex editor) and there wasn't

That script I used :https://github.com/geniusprodigy/bitcoin-qt
+ I'll try electrum way but I dont feel like it will work + what to do with another adresses if import some of them doing new wallet?
Sadderr (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
April 22, 2024, 12:37:12 PM
 #28

If so, you may have to specify which address type to dump because the command defaults to "bech32" if addresstype isn't explicitly set.
Since you do not know the actual address(es), you may have to create a separate dump with legacy and p2sh-SegWit addresses.

Holy moly, this is new to me, thanks for this! I just looked up the short help with bitcoin-cli help dumpwallet (Bitcoin Core v26.0) and there's absolutely no reference to addresstype whatsoever affecting the output of this command. I'm puzzled, need to investigate further.

When dumpwallet is affected by settings in bitcoin.conf like addresstype=legacy, it might be necessary to also specify changetype=legacy for change addresses (for legacy address type here).


I haven't import them on electrum cause i have found a python script that work for checking the balance of accounts and I tried with all of the addresses and every account was 0
And I put some random adresses with balance(not mine) and the script found them  
So that what make me know that adresses all empty

I'd rely at such an important verification step on proven tools like Electrum wallet. Your Python script may be OK, but how do you know after just a few tests? Your script may just skip gracefully without signaling issues if it's programmed the wrong way. If you don't understand the code, you can't know what it is doing. I would be careful with "unknown" scripts.

You don't give any details about the script and it's a bit annoying to always have to ask for further details. I mean, you should be the one who is very much interested to be certain to use the right tools, no?


What address type did you get in your output file of dumpwallet command (public addresses of 1... / 3... or bc1q...)?

I'll try electrum  one but I dont put a hope for it
In my previous comment I have put the script link

It's not (not giving any details ) I'm just lost the hope and the energy that it can have anything on it
And I'm replying with what you asking for

The adresses types all of them was starting with 3
Cricktor
Legendary
*
Offline Offline

Activity: 938
Merit: 1460


Crypto Swap Exchange


View Profile
April 22, 2024, 12:50:02 PM
Last edit: April 22, 2024, 07:30:33 PM by Cricktor
Merited by ABCbits (3)
 #29

You don't need to full quote always, not to mention that consecutive posts aren't allowed either (see forum rules #13 and #32).

I think it's gonna be useless because yesterday when I'm trying I used (getbalance) on btc core and it shows 0.000 I dont remember how many zeros but there wasn't another numbers

getbalance will only work properly and give a reliable balance when your Bitcoin Core is fully synced and the wallet addresses have all been fully scanned (rescanned if necessary) over the whole blockchain.


That script I used :https://github.com/geniusprodigy/bitcoin-qt

I can't remember having seen this script you found, but I'm far from knowing a lot of them. I stick to proven tools that are well known and that I mostly can understand myself, but I'm no programmer or coder.

Your script queries blockchain.info to get balances and what if blockchain.info has some rate limits for querying a lot of addresses. I don't see too much exception handling in the script, especially when blockchain.info wouldn't give good answers.

If I were you, I'd use Electrum.


The adresses types all of them was starting with 3

P2SH-Segwitt address type (3...) seems to be default for at least Bitcoin Core 26.0. --- edit: see following post

Follow advise of nc50lc and create dumpwallet files with

addresstype=legacy
changetype=legacy

in your bitcoin.conf and another dumpwallet file with

addresstype=bech32
changetype=bech32

in your bitcoin.conf, so that you have all three address types covered.

█▀▀▀











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











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

Activity: 2590
Merit: 6366


Self-proclaimed Genius


View Profile
April 22, 2024, 01:49:28 PM
Merited by vapourminer (1), RickDeckard (1)
 #30

-snip-
I think it's gonna be useless because yesterday when I'm trying I used (getbalance) on btc core and it shows 0.000 I dont remember how many zeros but there wasn't another numbers
It's 0.00000000 BTC, so is you Bitcoin Core fully synced?
Because if not, getbalance will just show you false-negative results regardless if the wallet has bitcoins.

If yes, then why did you have to go through the unsafe dumpwallet and manual/scripted balance checking if you're going to sync Bitcoin Core anyways?

What's done is done and if it's the actual balance Bitcoin Core shows,
then the wallet is really empty since it already checked all script types derived from the wallet's private keys.

Quote from: Sadderr
Also: on the first I tried to search for (name ) on wallet.dat file by notepad (normal one) and hxd (hex editor) and there wasn't
The former isn't reliable specially if the backup is an unused copy of the wallet.dat file.
Without any history of usage, you wont find any address using that method.

P2SH-Segwitt address type (3...) seems to be default for at least Bitcoin Core 26.0.
It's been "bech32" since v20.0: github.com/bitcoin/bitcoin/blob/master/doc/release-notes/release-notes-0.20.0.md#wallet

█▀▀▀











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











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Pages: « 1 [2]  All
  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!