Post
Topic
Board Wallet software
Re: Need help recovering private key from 2009-2010
by
whanau
on 08/12/2023, 19:59:42 UTC
Thanks. Then how would I use the result? Just convert the hex to another format?

If you are familiar with python, you could use this script (offline) or any of the other software suggested.

Code:
from bitcoinaddress import Wallet


# Convert a string with hex digits, colons, and whitespace to a long integer
def hex2int(hexString):
    return int("".join(hexString.replace(":", "").split()), 16)


dA  = hex2int('54040CDA88EE1CA322FEB4BD61C1098224222444F9453637802FE66526674199')
# put your test key between the ' ' the key above is to demonstrate

dx = str(f'{dA:064x}')
wallet = Wallet(dx)
priv_key = wallet.key.hex
wif = wallet.key.mainnet.wif
publ_key = wallet.address.pubkey
publ_keyc = wallet.address.pubkeyc
address = wallet.address.mainnet.pubaddr1
addressc = wallet.address.mainnet.pubaddr1c
address3 =wallet.address.mainnet.pubaddr3
wifc = wallet.key.mainnet.wifc

addressd = wallet.address.mainnet.pubaddrbc1_P2WSH
addresse = wallet.address.mainnet.pubaddrbc1_P2WPKH

print('Private key : ' + str(priv_key) + '\n' +
      'Public key  : ' + str(publ_key) + '\n' +
      'Address     : ' + str(address) + '\n' +
      'WIF         : ' + str(wif) + "\n\n" +
      'Public key C: ' + str(publ_keyc) + '\n' +
      'Address    C: ' + str(addressc) + '\n' +
      'WIF        C: ' + str(wifc) + "\n\n" +
      'BC1 P2WSH   : ' + str(addressd) + '\n' +
      'BC1 P2WPKH  : ' + str(addresse) + '\n' +
      'P2SH        : ' + str(address3) + '\n')