
How we recovered $300k of Bitcoin - mathgenius
https://reperiendi.wordpress.com/2020/04/03/how-i-recovered-over-300k-of-bitcoin/
======
aresant
"I’m currently looking for work in a staff or senior staff engineering or data
scientist role. If you’ve got interesting technical analysis or optimization
problems, please reach out to me and let’s talk."

That is probably the best CV I've ever read by accident.

You should broaden your job hunt criteria to technical content marketing -
seriously!

Very rare to possess the skill to tell a story in an entertaining,
approachable and detailed technical fashion.

~~~
metaweta
Hahaha, thanks!

~~~
hanniabu
> If you’ve got interesting technical analysis...

FYI, not sure if english is your first language or not but this should be "If
you have interesting technical analysis..."

~~~
dantillberg
"If you've got" may not be formal "correct" English, but everyone understands
it and it's used quite commonly in daily speech (and writing). I would wager
that "if you've got" may actually be preferable to "if you have," in order to
engage the reader at a more comfortable, personal level.

~~~
pbhjpbhj
FWIW "you've got" seems very US American to me (native en-gb).

~~~
YooLi
“You’ve got mail!”

------
sireat
The author is a very talented applied cryptographer with a very impressive
resume (he is looking for new projects).

The following CV line stands out however:

Google: Software Engineer, Ads Review. June 2014– March 2016.

Angular / Java developer on the internal tool used by contractors to review
Google ads for policy violations.

How did that saying about "brightest minds working on ads" go?

I am not blaming the author as I would have done the same(and I imagine author
was not told when hired that he'd be working on Java/Angular ad tool).

Again it is not that Java or Angular are bad per se, but working on ad CRUD
seems completely orthogonal to author's talents.

~~~
jodrellblank
> _How did that saying about "brightest minds working on ads" go?_

I think it goes something like the Open Source saying "that person doesn't owe
anyone their intelligence to work on so-called important problems for free,
just because it might be nice if they did".

Want smart people to solve important problems? Find a way to pay more for
that, than for ads, or find a way they don't need to earn money to live at the
standard they want.

~~~
joosters
Never going to happen. Look at other important jobs - doctors and nurses can
have very low wages, while professional footballers earn millions. We all know
which one is more important, but there's no way the medics will ever get paid
comparably.

~~~
wolco
Some top doctors can earn at least nba coach level figures. Frontline workers
testing people will never make that amount because the skill level is lower so
more people can do the work. If everyone refused and only a handful of people
were left they couldn't reproduce the same impact anyhow and the program would
close instead of paying them millions. Together they have a big impact and one
on one they have a big impact but a single first responder doesn't have the
attention or connection of millions. Would you put a poster of Jill, Nurse 56
from Grandrapids who works in the covid wing cleaning sheets? Probably not,
even though the job is extremely important.

~~~
pbhjpbhj
>Some top doctors can earn at least nba coach level figures //

Ethically?

~~~
wolco
Sure everything from plastic surgeons to heart specialists. Not everyone has
to be a doctor to the stars or go on shark tank to make millions. Does your
local walkin clinic doctor make that? No, but would make 500k before
expensives.

------
beamatronic
”Until a man is twenty-five, he still thinks, every so often, that under the
right circumstances he could be the baddest motherfucker in the world. If I
moved to a martial-arts monastery in China and studied real hard for ten
years. if my family was wiped out by Colombian drug dealers and I swore myself
to revenge. If I got a fatal disease, had one year to live, devoted it to
wiping out street crime. If I just dropped out and devoted my life to being
bad. Hiro used to feel that way, too, but then he ran into Raven. In a way,
this is liberating. He no longer has to worry about trying to be the baddest
motherfucker in the world. The position is taken.”

~~~
55555
Thanks for this quote. I've added Snow Crash to my want-to-read list.

------
aazaa
> Recovering the key was usually instantaneous, but to help people feel like
> they’d gotten their money’s worth, we’d put on a little animated show like a
> Hollywood hacking scene with lots of random characters that gradually
> revealed the right password.

and later ...

> I’m currently looking for work in a staff or senior staff engineering or
> data scientist role. If you’ve got interesting technical analysis or
> optimization problems, please reach out to me and let’s talk.

I can't help but wonder if this write-up (which is fascinating) may not be one
of those little animated shows to help propspective employers feel like
they'll get their money's worth.

~~~
DangitBobby
That's an incredibly cynical take.

~~~
logarhythmic
Right? Jesus...

------
jodrellblank
@metaweta: The technical side is interesting, but seems like the admin side
would be too; how did the administration and contract side play out?

Someone needed to front an estimated $100k of GPU costs, without being sure it
would work - and then pay for your work on top; who risked that? You had no
proof the claimed Bitcoins inside were real, or as many as claimed. You're in
New Zealand(?) and the customer is in Russia - you need the file to study it
and if you crack it then you have the Bitcoins as well - how did they become
comfortable that you wouldn't steal them and say you couldn't crack it? Did it
worry you that the owner might not be able to convert them to cash, e.g. if
the Exchange was shady and there was very little recourse?

How much work did it take to convince your partner to stop what they were
doing, and write GPU code for a crack which might not work?

~~~
metaweta
I'm in the USA. He paid us for some work up front and agreed to pay the rest
on delivery of the key. He expected to spend most of the $100K he'd budgeted
on GPU costs, so we got much less than that for the work; we took the job
because it sounded like fun. We didn't need the information in the archived
files, just the encryption headers, so he set most of the bytes to zero. I
couldn't have spent the coins even if I wanted to.

~~~
jodrellblank
Thank you, that is interesting; he's wealthy enough and technically capable
enough to make that all go a lot easier. (I guessed from going back to check
on the process ID on his laptop that you must have had his laptop, and didn't
know you could do that with just headers).

------
Abishek_Muthian
Not only are the cryptography skills of Mr. Mike Stay is obviously impressive,
his presentation of things which happened 20 years ago in a vivid yet subtle
manner seems extraordinary to me.

Especially since, I can't remember what I did 2 weeks back to write in my
blog.

Can you give us the secret of your documentation/notes workflow Mr. Mike
(@metaweta)? Please don't say that you recalled from your memory!

~~~
metaweta
I kept a Cryptonomicon!

------
WheelsAtLarge
I always assumed that the encryption used on zip files was relatively trivial
and could be broken given the right software and hardware.

Well, it looks like it's a lot harder than I thought. You still need the right
software and hardware but you also need the right person to do it.

Most of what I read was above my understanding but it was good reading anyhow.
Good job on the recovery and good job writing about it.

~~~
spopejoy
You're not alone, wikipedia for zip says

> ZIP supports a simple password-based symmetric encryption system generally
> known as ZipCrypto. It is documented in the ZIP specification, and known to
> be seriously flawed. In particular, it is vulnerable to known-plaintext
> attacks, which are in some cases made worse by poor implementations of
> random-number generators.
> [https://en.wikipedia.org/wiki/Zip_(file_format)#Encryption](https://en.wikipedia.org/wiki/Zip_\(file_format\)#Encryption)

IMO the fact that the author was able to recover the password at all indicates
weakness. Something encrypted with AES-GCM would presumably be all but
impossible.

------
hirundo
This may be the plutonic ideal of a Hacker News story. It's also sort of a
Travis McGee story but the salvage consultant is a cryptographer.

~~~
SlowRobotAhead
It got me with SoftIce. Although I never thought to print them out; I needed
to watch all the registers change as I was doing similar work or reverse
engineering encryption schemes.

~~~
hippich
I did not have a printer at that time. Notepad with a lot of addresses and
registers' values... Also, did not realize one can print from the SoftIce
directly, as I assumed it run at the lowest level before all the printer
drivers. Certainly, it would be super useful!

------
lwb
I've always wondered what the development process looks like for these type of
algorithms. If you have to run the program for a year to know if it will work,
how can you have any confidence that what you've written is going to do the
trick?

~~~
saagarjha
Perhaps you try it on smaller, "test" data to see if it works?

~~~
metaweta
Exactly. We created some zip files we knew the password to and then checked
that our code found the right one. Each stage would generate a bunch of files
with different candidate ranges, so when testing the next stage, we'd choose
the one file we knew had the correct key in it.

------
sheikheddy
Does anyone have links to stories that are as good as this? I want to binge
blog posts that teach and entertain at the same time.

~~~
mleonhard
I've been learning Rust. Reading "The Rust Book" and "Rust By Example" gave me
a similar feeling as reading this blog post.

------
schemescape
I kept expecting to read that the password on the zip file turned out to be
“password123” or something like that.

~~~
ape4
I want to know the password too. If it was machine generated looking at that
algo might have been useful.

------
prtkgpt
NEARProtocol.com is hiring. Please have a look.
[https://nearprotocol.com/careers/#openings](https://nearprotocol.com/careers/#openings)
and I can connect you with our recruiting team. Thanks :)

~~~
metaweta
Looking, thanks!

~~~
louwrentius
You are smart beyond my comprehension. Your article was amazing.

Although blockchain technology fits your skillset, I hope you will choose to
do something [actually|more] worthwhile to our societies.

------
ddrt
"I knew of one place that ran the software for nine months before finally
getting in."

And what a beautiful new baby password crack it was.

------
tiborsaas
Attacking the wetware would have been worthy try :) Would hypnosis work to
recover the forgotten password?

~~~
metaweta
He actually tried that without success.

~~~
ur-whale
Any reason why a dictionary based attack wasn't tried first?

Or did your client remember selecting something really hard in the first
place?

~~~
metaweta
Yeah, he knew it was a long passphrase.

------
apirone
Collected the biggest archive of Bitcoin wallet.dat files with balance and
lost passwords.
[https://allprivatekeys.com/wallet.dat](https://allprivatekeys.com/wallet.dat)
The collection consists of 32 files total for 2500+ BTC. The biggest wallet
576 BTC, the most interesting wallet.dat files with pre-mined coins from
2009-2010. Let's try other wallets for a share?

------
carlsborg
Great story and impressive work at Pyrofex. Can you share your perspective on
the crypto industry right now?

~~~
metaweta
There's no way that the AccessData job I had would exist today. Most services
are online, with data encrypted in transit and stored in the cloud. TLS
security has improved dramatically over the last decade in response to attacks
like BEAST and BREACH and CRIME and POODLE. Google drops (? is going to drop?)
your SEO ranking if you don't have proper certs installed. Nowadays, it's rare
to find an attack on the connection from the browser to the server. Instead,
it's either malware on the client or hacking into the servers, where the
operators have terrible security practices like storing data unencrypted at
rest.

The field of cryptography has grown tremendously, and there's still a lot of
research being done. There have been many competitions for developing strong
cryptographic primitives. There's a lot of work being done on zero knowledge
proofs and verifiable computation. Cryptocurrency has encouraged lots of
bright young minds to get involved.

One thing we learned from the Snowden revelations is that crypto works where
it's applied, so every little bit of crypto helps. Run a Tor node if you can.

~~~
carlsborg
Thanks. Is an implementation of the Casanova and c delta blockchain papers in
the works? I don’t see it on GitHub.

------
Gatsky
The technical proficiency on display here makes me swoon.

------
mianos
No one said TLDR this article, ever. This account has all the components of
great book. It reminds me of 'The Soul of a New Machine'.

------
enimodas
How off was the 100k compute time estimation?

~~~
metaweta
I think he ended up only spending around $5-10K on compute. I'd have to check
with Nash.

------
remarkEon
What am amazingly fun read. Beyond the obvious technical skills, OP is a great
writer.

------
gatleon
Great story. I just wish the title was in BTC rather than USD.

~~~
FabHK
The story would be less thrilling, I think: someone bought around 35 BTC, and
then later he desperately wanted access to them, because they were worth 35
BTC!

~~~
metaweta
lol yeah

------
Trias11
Resume of the decade!

------
TedDoesntTalk
excellent story. can you share the number of bitcoins that were retrieved and
how the customer lost the password in the first place?

~~~
saagarjha
> Back in January of 2016, he had bought around $10K or $15K of Bitcoin and
> put the keys in an encrypted zip file.

Based on the price of Bitcoin back then, it seems like this was about 30-40
Bitcoin?

~~~
tomglynch
Was the computer stolen or did he actually forget the password?

~~~
gwbas1c
From TFA:

> Luckily, he still had the original laptop and knew exactly when the
> encryption took place.

------
fitzn
This is such a cool story. Thank you, Mike!

------
samstave
That was an amazing read!

------
ackbar03
This is pretty hardcore

------
zomglings
What a great story - a surefire cure for Dunning-Kruger. I'm in awe of this
guy.

------
kortilla
How could you be sure you didn’t just help heist someone’s bitcoin that this
Russian snatched with some malware?

~~~
DeathArrow
> Luckily, he still had the original laptop and knew exactly when the
> encryption took place.

~~~
kortilla
But how do you prove that? It’s trivial to replicate the hardware the file was
lifted from if the malware grabbed the standard sys info. File create/modify
times could also give you a pretty damn good guess as to when the encryption
happened.

------
ngold
I don't know why, but these headlines disgust me. There is no insight. Just.
Headline of greed.

~~~
maaarghk
"How we cracked a zip file" would have been pretty shitty though, right?

------
shanusmagnus
If some random Russian dude shows up and offers to pay $100k to crack
something with untraceable digital currency inside, don't you worry about
getting killed if you fail to do it? Maybe I watch too much TV.

~~~
sneak
This is racism.

