JoelKatz
Legendary
Offline
Activity: 1596
Merit: 1012
Democracy is vulnerable to a 51% attack.
|
|
August 08, 2011, 03:27:50 AM |
|
While I wouldn't put it past anyone, that rainbow table is going to be ridiculously slow to build to the point of near infeasibility. The operation of deriving the public key from the private key, as I'm sure you know, is super expensive in CPU time. You only need to do it once. But yeah, trillions is going to be awfully tough.
|
I am an employee of Ripple. Follow me on Twitter @JoelKatz 1Joe1Katzci1rFcsr9HH7SLuHVnDy2aihZ BM-NBM3FRExVJSJJamV9ccgyWvQfratUHgN
|
|
|
Departure
|
|
August 08, 2011, 03:50:45 AM |
|
Okay so I have no problems generating a SHA256 hash, personally I would use multiple hash algo's on my passowrd pharse which included a key , then I would Vigenere Encrypt that, or Xor then MD5 hash that and then finally SHA256 the result to generate a custom SHA256 key. now my question is how do I use that generated SHA256 hash in the bitcoin client as a wallet address? I have only just started using the bitcoin client as a wallet since mybitcoin problems. Could someone explain how to use a custom generated SHA256 key as there wallet address in the bitcoin client please?
|
|
|
|
ctoon6
|
|
August 08, 2011, 04:04:43 AM |
|
Okay so I have no problems generating a SHA256 hash, personally I would use multiple hash algo's on my passowrd pharse which included a key , then I would Vigenere Encrypt that, or Xor then MD5 hash that and then finally SHA256 the result to generate a custom SHA256 key. now my question is how do I use that generated SHA256 hash in the bitcoin client as a wallet address? I have only just started using the bitcoin client as a wallet since mybitcoin problems. Could someone explain how to use a custom generated SHA256 key as there wallet address in the bitcoin client please?
https://github.com/jackjack-jj/pywallet
|
|
|
|
netrin
Sr. Member
Offline
Activity: 322
Merit: 251
FirstBits: 168Bc
|
|
August 08, 2011, 06:31:18 AM |
|
$ echo your mom | sha256sum 6e96e45029870a9b08cff2ed6ac840ccde3edce244327cc1bddefa1e555bc81f -
$ gpg --print-md sha256 < /dev/stdin<Enter> <your passphrase><Enter> <Ctrl-D><Ctrl-D>
which gives the same results as
$ gpg --print-md sha256 <file><Enter>
|
|
|
|
JoelKatz
Legendary
Offline
Activity: 1596
Merit: 1012
Democracy is vulnerable to a 51% attack.
|
|
August 08, 2011, 06:36:52 AM |
|
$ echo your mom | sha256sum 6e96e45029870a9b08cff2ed6ac840ccde3edce244327cc1bddefa1e555bc81f -
The 'echo' command, by default, puts a newline at the end of its input. You can suppress this behavior with '-n'. (You can do it either way, but this may explain why different tools might given different results.)
|
I am an employee of Ripple. Follow me on Twitter @JoelKatz 1Joe1Katzci1rFcsr9HH7SLuHVnDy2aihZ BM-NBM3FRExVJSJJamV9ccgyWvQfratUHgN
|
|
|
indio007
|
|
August 08, 2011, 06:51:16 AM |
|
So let me get this straight. You can create a private key with a passphrase import it into a wallet. Transfer funds to it and then delete the wallet.dat and recover it by repeating the process?
|
|
|
|
ctoon6
|
|
August 08, 2011, 06:51:53 AM |
|
So let me get this straight. You can create a private key with a passphrase import it into a wallet. Transfer funds to it and then delete the wallet.dat and recover it by repeating the process?
yep
|
|
|
|
indio007
|
|
August 08, 2011, 06:55:58 AM |
|
Effing sweet! What are the odds of someone using the same private key. I've actually been wondering this for a awhile. What is someone just tries to hoard all possible private keys? Or is it the keypair that matters?
|
|
|
|
benkebab
Member
Offline
Activity: 75
Merit: 10
|
|
August 08, 2011, 07:12:01 AM |
|
Hey, I'm quite new to bitocin so I just wondered: why are they several private keys stored in a wallet.dat? Given what you explained, you only need to know 1 private key, right?
|
|
|
|
ctoon6
|
|
August 08, 2011, 07:13:48 AM |
|
Hey, I'm quite new to bitocin so I just wondered: why are they several private keys stored in a wallet.dat? Given what you explained, you only need to know 1 private key, right? its soposed to give more anonymity. however i find it pointless, and would rather the client just make a new address when requested.
|
|
|
|
kloinko1n
|
|
August 08, 2011, 09:47:54 AM |
|
$ echo your mom | sha256sum 6e96e45029870a9b08cff2ed6ac840ccde3edce244327cc1bddefa1e555bc81f -
$ gpg --print-md sha256 < /dev/stdin<Enter> <your passphrase><Enter> <Ctrl-D><Ctrl-D>
which gives the same results as
$ gpg --print-md sha256 <file><Enter>
Yes, that's much better than my 'solution', thanks! [snip> The 'echo' command, by default, puts a newline at the end of its input. You can suppress this behavior with '-n'. (You can do it either way, but this may explain why different tools might given different results.)
Thanks for the addition, very helpful!
|
|
|
|
oOoOo
|
|
August 08, 2011, 10:12:28 AM |
|
So let me get this straight. You can create a private key with a passphrase import it into a wallet. Transfer funds to it and then delete the wallet.dat and recover it by repeating the process?
No. Once you spend your coins from the imported address, the change will be returned to a new address stored in your wallet. If you delete it then, you will lose everything. What you have to do after the import, is to send the entire remaining amount back to your chosen address in a new transaction. .
|
|
|
|
jackjack
Legendary
Offline
Activity: 1176
Merit: 1257
May Bitcoin be touched by his Noodly Appendage
|
|
August 08, 2011, 10:26:17 AM |
|
So let me get this straight. You can create a private key with a passphrase import it into a wallet. Transfer funds to it and then delete the wallet.dat and recover it by repeating the process?
You don't have to import the key to transfer funds to it, and should not do it
|
Own address: 19QkqAza7BHFTuoz9N8UQkryP4E9jHo4N3 - Pywallet support: 1AQDfx22pKGgXnUZFL1e4UKos3QqvRzNh5 - Bitcointalk++ script support: 1Pxeccscj1ygseTdSV1qUqQCanp2B2NMM2 Pywallet: instructions. Encrypted wallet support, export/import keys/addresses, backup wallets, export/import CSV data from/into wallet, merge wallets, delete/import addresses and transactions, recover altcoins sent to bitcoin addresses, sign/verify messages and files with Bitcoin addresses, recover deleted wallets, etc.
|
|
|
netrin
Sr. Member
Offline
Activity: 322
Merit: 251
FirstBits: 168Bc
|
|
August 08, 2011, 12:49:44 PM |
|
I hope alternate clients consider addresses more like accounts (with change returned to the same by default) and move this non-deterministic 'wallet' as an optional part of a greater laundering/anonymity regime. The wallet with newly generated keys is a major source of confusion and the anonymity provided is a joke. Only geeks 'get it' - everyone else has to learn the hard way.
I think it would be wildly cool to pass a slip of paper "The dog barks at midnight 3879273". The ultimate swiss bank account. Or "Congratulations My Son 8360324" or "Bitcoin gold parity. I told you so. Haz Haq Hah! Pennies for the poor."
|
|
|
|
kloinko1n
|
|
August 08, 2011, 12:59:40 PM |
|
Oh, by the way, echo your mom | sha256sum deletes any trailing spaces in "your mom", "your mom ", "your mom " etc.
|
|
|
|
netrin
Sr. Member
Offline
Activity: 322
Merit: 251
FirstBits: 168Bc
|
|
August 08, 2011, 01:04:06 PM |
|
$ echo -n " your mom " | sha256sum 888eb5c57140830728b64def5c3d9230f8b7f8d6567814542a92259be16e6007 -
|
|
|
|
kloinko1n
|
|
August 08, 2011, 01:48:28 PM |
|
$ echo -n " your mom " | sha256sum 888eb5c57140830728b64def5c3d9230f8b7f8d6567814542a92259be16e6007 - Ok Question sneakily inserted: Is the ownership of the file blk0001.dat the same as that of the file blkindex.dat? (I thought I might as well ask that in here as you guys seem to know everything anyway, and my question isn't being answered where I originally posed it.)
|
|
|
|
casascius (OP)
Mike Caldwell
VIP
Legendary
Offline
Activity: 1386
Merit: 1140
The Casascius 1oz 10BTC Silver Round (w/ Gold B)
|
|
August 08, 2011, 03:44:58 PM |
|
So let me get this straight. You can create a private key with a passphrase import it into a wallet. Transfer funds to it and then delete the wallet.dat and recover it by repeating the process?
No. Once you spend your coins from the imported address, the change will be returned to a new address stored in your wallet. If you delete it then, you will lose everything. What you have to do after the import, is to send the entire remaining amount back to your chosen address in a new transaction. . The answer to Indio007's question is "yes in theory", but with the current client, the answer "no" is correct to the extent that the change is likely to go to a newly generated address. I'd be willing to bet that "pywallet" either does, or could be trivially modified, to fill the unused keypool within wallet.dat with hundreds or thousands of pre-generated addresses that can be derived from the passphrase so the bitcoin client didn't have to. One passphrase can seed thousands or millions or any number of bitcoin addresses, all of which can be recovered with the same passphrase. If passphrase is "my passphrase", then the first address is based on "my passphrase1" and the second on "my passphrase2", and the millionth on "my passphrase1000000". IIRC, bitcoind only adds keys to the key pool if the number of keys in the pool falls below 100. If you used a deterministic wallet generator to generate a wallet.dat with 10,000 addresses - most of them going into the key pool - you would probably never need to worry about the change going to a new address.
|
Companies claiming they got hacked and lost your coins sounds like fraud so perfect it could be called fashionable. I never believe them. If I ever experience the misfortune of a real intrusion, I declare I have been honest about the way I have managed the keys in Casascius Coins. I maintain no ability to recover or reproduce the keys, not even under limitless duress or total intrusion. Remember that trusting strangers with your coins without any recourse is, as a matter of principle, not a best practice. Don't keep coins online. Use paper or hardware wallets instead.
|
|
|
Phinnaeus Gage
Legendary
Offline
Activity: 1918
Merit: 1570
Bitcoin: An Idea Worth Spending
|
|
August 08, 2011, 03:53:46 PM |
|
Say HI to address collisions. Only if two people use the same passphrase. '123456' is pretty common How about "Is Bargle with you?"
|
|
|
|
Mike Moceri
Newbie
Offline
Activity: 38
Merit: 0
|
|
August 08, 2011, 06:00:05 PM |
|
It would be REALLY cool if the bitcoin client could do this whole process automatically. Don't even have a wallet.dat flile; just have the user input a passphrase that will automatically convert to an SHA2 hash and store in memory throughout the session. Bloody brilliant idea, OP.
I do worry about accidental duplication of passphrases, though. I would want to come up with one that combines an easy to remember phrase, some arbitrary data (DOB, birthplace, mother's maiden name...), and some random data (Rand()).
|
|
|
|
|