Bitcoin Forum

Bitcoin => Bitcoin Discussion => Topic started by: Gareth Nelson on September 02, 2011, 12:33:13 AM



Title: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 12:33:13 AM
It's also encrypted with an XOR one-time pad on linux using /dev/urandom:

http://sprunge.us/FDGR


If someone cracks it, all I ask is you tell me how you did so.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: PwrLeveld on September 02, 2011, 12:36:16 AM
Looks, thinks for a second, fuck it.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 12:39:03 AM
Looks, thinks for a second, fuck it.

Is that a "fuck it, i can't do this?" or a "fuck it, i'll crack it" ?


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Vladimir on September 02, 2011, 12:40:18 AM
Quote
XOR one-time pad on linux using /dev/urandom

didn't even look at it, I pass


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: PwrLeveld on September 02, 2011, 12:43:59 AM

Is that a "fuck it, i can't do this?" or a "fuck it, i'll crack it" ?

Its a Fuck I would rather get hit by another hurricane and lose power for 3-4 days then even try.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: greyhawk on September 02, 2011, 12:46:13 AM
encrypted with an XOR one-time pad on linux using /dev/urandom:

No thanks.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: wolftaur on September 02, 2011, 12:46:32 AM
Quote
XOR one-time pad on linux using /dev/urandom

didn't even look at it, I pass

If I'm going to turn random data into a wallet, I'd rather turn it into the mybitcoin scammer's wallet. Then I'd have sooooo many coins. :)

(If you don't get how that makes logical sense go read up on OTPs...)


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: bosschair on September 02, 2011, 12:56:56 AM
If that file you posted is XOR'd with data from /dev/urandom, I think your /dev/urandom is broken.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 12:57:44 AM
There is a weakness in it, i'm not going to reveal it - want to see if anyone in this community spots it.

A professional cryptographer would spot it in seconds.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 12:58:29 AM
If that file you posted is XOR'd with data from /dev/urandom, I think your /dev/urandom is broken.

Do tell!
Have you found the weakness?


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: bosschair on September 02, 2011, 01:02:49 AM
The file is just a PNG of some kind of masonic symbol.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:05:02 AM
The file is just a PNG of some kind of masonic symbol.


With the right key of course it is ;)

But that's not the point here


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: fcmatt on September 02, 2011, 01:26:12 AM
I guess the only thing i can think of is that urandom is not as good as random.
As in it might just use a seed number. Also he appears to have limited his characters to printable stuff?


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: sveetsnelda on September 02, 2011, 01:30:45 AM
There is a weakness in it, i'm not going to reveal it - want to see if anyone in this community spots it.

A professional cryptographer would spot it in seconds.
I see it as well.  Maybe I'll give it a go tonight if nobody else gets around to it.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:39:18 AM
I guess the only thing i can think of is that urandom is not as good as random.
As in it might just use a seed number. Also he appears to have limited his characters to printable stuff?

It's base64 encoded silly.

Clue:
wallet.dat has structure and urandom is not truely random


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: sveetsnelda on September 02, 2011, 01:40:48 AM
I see it as well.  Maybe I'll give it a go tonight if nobody else gets around to it.
Nevermind...   found 0.10 BTC.  Your urandom is certainly broken.  It wasn't XOR'd at all...


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: fcmatt on September 02, 2011, 01:41:44 AM
I guess the only thing i can think of is that urandom is not as good as random.
As in it might just use a seed number. Also he appears to have limited his characters to printable stuff?

It's base64 encoded silly.

Clue:
wallet.dat has structure and urandom is not truely random

yea.. i was hoping to correct my post before someone quoted me..
and b64decode seems to have trouble with it on fbsd. no begin line. i will google.
ah.. -r fixed that issue.. but it seems i am too late.

But I am very curious what the solution was.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:42:18 AM
I see it as well.  Maybe I'll give it a go tonight if nobody else gets around to it.
Nevermind...   found 0.10 coins.  Your urandom is certainly broken.  It wasn't XOR'd at all...

LOL

Well done, for the record here's the correct one:
http://sprunge.us/PcLi


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: sveetsnelda on September 02, 2011, 01:43:51 AM
*That* looks better.  Now let's take a look...  :D


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:44:29 AM
*That* looks better.  Now let's take a look...  :D

You have the plaintext, don't do the obvious to crack it


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:45:06 AM
Oh, if you crack the correct one i'll send 1BTC to the address in the wallet


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: sveetsnelda on September 02, 2011, 01:46:38 AM
*That* looks better.  Now let's take a look...  :D

You have the plaintext, don't do the obvious to crack it
Oh.  For some reason I was thinking that he posted a 2nd one (like the first one was just a teaser).


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: sveetsnelda on September 02, 2011, 01:47:16 AM
Oh, if you crack the correct one i'll send 1BTC to the address in the wallet
Are they two separate wallets, then?


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:47:57 AM
Oh, if you crack the correct one i'll send 1BTC to the address in the wallet
Are they two separate wallets, then?

No, hence my request that you not do the obvious to crack it.
Tell me how to crack it without having the plaintext and i'll send you 1BTC.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: fcmatt on September 02, 2011, 01:50:39 AM
I think I am a bit confused now.

The first was simply based64 encoded. The person who won decoded it and earned the btc.

Now you have a second file which when decoded is obviously not a wallet.dat file straight away.

Is this the same wallet.dat file but encrypted with a one time pad using urandom?


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: sveetsnelda on September 02, 2011, 01:51:17 AM
Well...  If urandom was used, it's certainly possible to crack (especially since the header of the file is the same between wallets).  That'd give you some possibilities of where the seed started.  However, it seems that different versions of Unix/Linux/BSD have different implementations of pseudo-random number generation.  We could go through them all, I guess...


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: fcmatt on September 02, 2011, 01:53:25 AM
Well...  If urandom was used, it's certainly possible to crack (especially since the header of the file is the same between wallets).  That'd give you some possibilities of where the seed started.  However, it seems that different versions of Unix/Linux/BSD have different implementations of pseudo-random number generation.  We could go through them all, I guess...

I was thinking that also. Freebsd does not even have urandom.. it just:

> ls -al /dev/ | grep ran
crw-rw-rw-   1 root     wheel       0,  11 Sep  8  2009 random
lrwxr-xr-x   1 root     wheel            6 Sep  8  2009 urandom -> random


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:54:04 AM
Well...  If urandom was used, it's certainly possible to crack (especially since the header of the file is the same between wallets).  That'd give you some possibilities of where the seed started.  However, it seems that different versions of Unix/Linux/BSD have different implementations of pseudo-random number generation.  We could go through them all, I guess...

To win the bounty you must present an algorithm.
The kernel version: 2.6.32-5


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:56:38 AM
By the way, after this one is cracked the next bounty will be 10BTC for one encrypted using the REAL entropy source.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: wolftaur on September 02, 2011, 01:56:48 AM
Well...  If urandom was used, it's certainly possible to crack (especially since the header of the file is the same between wallets).  That'd give you some possibilities of where the seed started.  However, it seems that different versions of Unix/Linux/BSD have different implementations of pseudo-random number generation.  We could go through them all, I guess...

To win the bounty you must present an algorithm.
The kernel version: 2.6.32-5

And when someone earns the bounty, everyone with the base64-decoded version tries spending the bounty first. :)


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 01:59:22 AM
Well...  If urandom was used, it's certainly possible to crack (especially since the header of the file is the same between wallets).  That'd give you some possibilities of where the seed started.  However, it seems that different versions of Unix/Linux/BSD have different implementations of pseudo-random number generation.  We could go through them all, I guess...

To win the bounty you must present an algorithm.
The kernel version: 2.6.32-5

And when someone earns the bounty, everyone with the base64-decoded version tries spending the bounty first. :)
No, because the next bounty will be in a new wallet - only the one who cracks it will get it.
For this one, i'll send the 1BTC when the winner agrees - they can then pay it out themselves to ensure it doesn't get stolen - plus it'll be fun to watch that bit anyway ;)


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: fcmatt on September 02, 2011, 02:11:29 AM
I am sitting here thinking what would he use for the seed value... his bitcoin address? his username?
There must be a clue I am not thinking of in his posts. To sit here and try to brute force it does not
seem like a valid plan of action.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 02:15:12 AM
I am sitting here thinking what would he use for the seed value... his bitcoin address? his username?
There must be a clue I am not thinking of in his posts. To sit here and try to brute force it does not
seem like a valid plan of action.

What would I use?
I use whatever the hell last went into the kernel entropy pool - and trust me, it's cycled a lot ;)


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 02:17:27 AM
I'll help you all out.
It was somewhere between 128 and 190 bits long.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: wolftaur on September 02, 2011, 06:37:31 AM
I'll help you all out.
It was somewhere between 128 and 190 bits long.

That's about as useful as the United States Congress.


Title: Re: I have pasted my wallet.dat base64-encoded, crack it and the contents are yours
Post by: Gareth Nelson on September 02, 2011, 10:15:45 AM
I'll help you all out.
It was somewhere between 128 and 190 bits long.

That's about as useful as the United States Congress.

It's all I know based on how much entropy that box drains.