Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: searstream on March 07, 2014, 06:20:59 AM



Title: Removing the possibility of duplicate private keys
Post by: searstream on March 07, 2014, 06:20:59 AM
Over the past couple of weeks I've kept thinking about private keys and their possible ways of being lost\stolen\duplicated.  As I understand it now, private keys should be generated as random as possible.  Now the idea of randomness is nice but from what I've learned over the years is that true randomness doesn't exist. Now I don't truly want to go down that rabbit hole I just want to discuss the possibility of someone randomly creating a new private key that has already been used. Then the creator of this duplicate key would have access to whatever bitcoins were associated with it.

Now, I've seen the math. I know the plausibility of this occurring is incredibly rare. But at the same time the world has a decent amount of things that should have never happen, happen. Also the fact that someone could try to duplicate a private key maliciously (I know the math behind this is also ludicrous, but put a big enough incentive and someone will try).

This all being said, I was trying to think of solutions to this minor problem almost non-problem at the current moment. I don't have a solution formed yet, but I keep thinking that there must be a way to load an encrypted private key onto the blockchain and then to us ether funds tied with that key you'd have to decrypt it with your password. I know there are holes here but that is why I'm writing this here to see if there are any solutions.

Last, I wouldn't mind someone telling me that I have all these concepts wrong and that this is and never will be an issue.


Searstream


Title: Re: Removing the possibility of duplicate private keys
Post by: bmanzzs on March 07, 2014, 07:37:50 AM
The chances of that happening is something like 1 in 2^160


Title: Re: Removing the possibility of duplicate private keys
Post by: itod on March 07, 2014, 03:03:11 PM
It's recommended you read this:
https://github.com/bitcoin/bips/blob/master/bip-0038.mediawiki (https://github.com/bitcoin/bips/blob/master/bip-0038.mediawiki)


Title: Re: Removing the possibility of duplicate private keys
Post by: whtchocla7e on March 07, 2014, 04:37:35 PM
If you control some Bitcoins, you live in constant fear.
There's just no other way around it.


Title: Re: Removing the possibility of duplicate private keys
Post by: RodeoX on March 07, 2014, 04:45:53 PM
I think you are correct that there is a mathematical *possibility of generating two identical private keys. But as mentioned, the chances are astronomically low. Like this game... Guess what number I am thinking of? It is between 0 and 9,999,999,999,999,999,999,999,999,999,999,999,999. I can accept as many guesses from as many people as want in.


Title: Re: Removing the possibility of duplicate private keys
Post by: DannyHamilton on March 07, 2014, 04:58:04 PM
I think you are correct that there is a mathematical *possibility of generating two identical private keys. But as mentioned, the chances are astronomically low. Like this game... Guess what number I am thinking of? It is between 0 and 9,999,999,999,999,999,999,999,999,999,999,999,999 1,460,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000. I can accept as many guesses from as many people as want in.

Fixed that for you.

Your range wasn't big enough.  It needed to be about 100,000,000,000 times as big.

Humans seem to be REALLY, Really, really bad and comprehending just how big "very big numbers" are.  I throw on a dozen extra zeros, and it seems like its just a handful more zeros. It doesn't seem like it makes a big difference, but it actually makes a huge difference.


Title: Re: Removing the possibility of duplicate private keys
Post by: RodeoX on March 07, 2014, 05:03:51 PM
I think you are correct that there is a mathematical *possibility of generating two identical private keys. But as mentioned, the chances are astronomically low. Like this game... Guess what number I am thinking of? It is between 0 and 9,999,999,999,999,999,999,999,999,999,999,999,999 1,460,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000. I can accept as many guesses from as many people as want in.

Fixed that for you.

Your range wasn't big enough.  It needed to be about 100,000,000,000 times as big.

Humans seem to be REALLY, Really, really bad and comprehending just how big "very big numbers" are.  I throw on a dozen extra zeros, and it seems like its just a handful more zeros. It doesn't seem like it makes a big difference, but it actually makes a huge difference.

Haha thanks Danny! My calculator caught fire before I had finished the math.

P.S. Hey can you PM me a BTC addy? I would like to send you a tip this weekend. Nobody deserves it more than you. Your helping of newbies is the kind of thing that moves bitcoin forward and creates the community. And your answers are the straight dope.
Props to you sir.  :)


Title: Re: Removing the possibility of duplicate private keys
Post by: teukon on March 07, 2014, 05:20:25 PM
I'll guess 985,127,014,233,505,270,335,875,346,337,305,767,271,122,687,733.

Did I win?


Title: Re: Removing the possibility of duplicate private keys
Post by: RodeoX on March 07, 2014, 05:35:33 PM
I'll guess 985,127,014,233,505,270,335,875,346,337,305,767,271,122,687,733.

Did I win?

Wow, close! My number was: 985,127,014,233,505,270,335,875,346,337,306,767,271,122,687,733

One number off. lol


Title: Re: Removing the possibility of duplicate private keys
Post by: teukon on March 07, 2014, 05:48:37 PM
I'll guess 985,127,014,233,505,270,335,875,346,337,305,767,271,122,687,733.

Did I win?

Wow, close! My number was: 985,127,014,233,505,270,335,875,346,337,306,767,271,122,687,733

One number off. lol

Damn it!

That was going to be my next guess.


Title: Re: Removing the possibility of duplicate private keys
Post by: DannyHamilton on March 07, 2014, 08:19:39 PM
Haha thanks Danny! My calculator caught fire before I had finished the math.

P.S. Hey can you PM me a BTC addy? I would like to send you a tip this weekend. Nobody deserves it more than you. Your helping of newbies is the kind of thing that moves bitcoin forward and creates the community. And your answers are the straight dope.
Props to you sir.  :)

PM Sent.


Title: Re: Removing the possibility of duplicate private keys
Post by: mustyoshi on March 08, 2014, 01:54:08 AM
If you really believe it to be a problem, 2 of 3 transactions double the key requirement, meaning they'd have to get 2 instead of just 1 keys to spend anything.