Author

Topic: Importing bitcoins from private key (Read 1731 times)

legendary
Activity: 1512
Merit: 1036
November 30, 2012, 03:22:36 PM
#4
If you have used Bitcoin in any capacity besides just receiving coins to one address, you likely have balances in several actual addresses/(privkeys). Bitcoin has an address pool of at least 100 more addresses you can't see. When you send a payment to someone, if you are not completely and exactly spending a sum of individual amounts sent to you, Bitcoin will send the remaining balance of unspent input coins back to you to one of these reserve addresses. Even after you have received change into a reserve address, the address is not shown to you in Bitcoin to avoid confusing people. Therefore, you must export all wallet addresses, not just one, unless you have the ability to determine the real balance on all 101+ addresses first.
member
Activity: 67
Merit: 130
November 16, 2012, 04:59:31 AM
#3
Nope. Compressed keys (default ones, since 0.7) start either from L or from K.
legendary
Activity: 1862
Merit: 1011
Reverse engineer from time to time
November 05, 2012, 10:37:17 AM
#2
Private keys in Bitcoin start with a 5. Always!
member
Activity: 75
Merit: 10
November 03, 2012, 09:31:40 PM
#1
I am having a weird issue that has been lingering for a while but I'm just now trying to get a handle on it. I had an old version of the bitcoin software installed on another computer and the bitcoin address in use was on that system. When I upgraded the bitcoin app, the wallet could no longer be read and would crash the app. I've since backed up the wallet.dat file and have now dumped all the keys from it to find the private key associated with one of the addresses. It was an address that Slush had sent bitcoins to because I hadn't changed the sending address yet, so now I have bitcoins lost in the etherverse (or whatever the hell you want to call it.

The wallet address was 1BVj9obg3TDPHLxYYP31nZBZBtgrdTBfkS, so when I used pywallet to dump the wallet contents, I found the wallet address on an "addr" line, but 2 lines down was the private key "5J4K........" on the "sec" line.

First off, is this the private key associated with that bitcoin address? Second, how do I get the coins back from it? I copied the key into the bitcoin debug using 'importprivkey 5J4K.......... OldWallet", and it did import, but when it did, I don't have bitcoins from the address, and there seems to be a new public address associated with it.

Any ideas?

UPDATE: I just took the pywallet output and threw it into a blockchain wallet. I seem to have my coins back now.

UPDATE 2: I seem to not quite have my coins back. Even after importing the pywallet dump and having the blockchain wallet see the available funds, when I try and send them to my new wallet, it is asking for the private address. When I copy what I assume is the private address, it says that it is a watch only address, so I can't send. I guess I'm stuck again.

Final UPDATE: I ran the old wallet through Gavins bitcointools and just output an updated wallet using fixwallet.py. I took the fixed wallet, renamed the current wallet and brought it in. Seems to have worked out, and I was able to send all its contents where I wanted it sent.
Jump to: