Satoshi’s coding profile matches Le Roux
Satoshi’s coding
The original Bitcoin client was written in Windows C++ and is an incredible production for any solitary coder. Not only did Satoshi get almost everything right, he also added innovative features such as the script language which would lead to rich directions for future developments. And yet there has been controversy whether Satoshi was an amateur or professional programmer.
In one sense this is absurd. Gavin Andresen, himself an elite programmer, said that Satoshi was in the top 10% of C++ developers he had known. Hal Finney, who had over thirty years professional programming experience, rated Satoshi highly:
“The reason I was skeptical about Dorian Nakamoto is that he didn’t match the picture in my mind that I had of Satoshi. I pictured him younger, as he was giving the impression of youthful vigor. Then there is the language Bitcoin was written in, C++. Satoshi was a master of the intricacies, and I’ve only seen this in young programmers. It seems hard to master C++ if you didn’t learn it while you’re young. […] I program in C, which is compatible with C++, but I don’t understand the tricks that Satoshi used.” (Hal Finney email, quoted by Forbes 25 Mar 2014)
Satoshi did not follow modern object-orientated good practice that younger professionals expected. His code was often dense, poorly documented and hard to follow. Security expert Dan Kaminsky tried to find weaknesses in the Bitcoin code but couldn’t. He remarked, “the way the whole thing was formatted was insane. Only the most paranoid, painstaking coder in the world could avoid making mistakes.” Kaminsky added, “He’s a world-class programmer, with a deep understanding of the C++ programming language. He understands economics, cryptography, and peer-to-peer networking.”
Satoshi was in his element giving support to users and issuing bug fixes. No one gets that good as an amateur. Some have speculated that Satoshi was someone who programmed professionally close to the metal, such as an electronics engineer. But that would not explain his expertise in C++.
Paul Le Roux’s coding
Let’s compare Satoshi’s programming style to Paul Le Roux’s experience. Coding was Le Roux’s life from the time he had a Commodore 64 as a teenager. He never attempted to get a degree and his only higher education was a one-year programming certificate in C and COBOL which he passed in just a few months. He left South Africa in 1992 at age 19 for Britain, getting a job with a small software outfit called Barrett Edwards, a company with ten employees. He stayed with them for a few years until he married an Australian woman and moved to Australia working as a contract programmer.
His CV at age 22 shows he was mainly a Windows C++ programmer although he had also completed projects in C and assembly. He would continue to specialise in C++ programming and had fifteen years professional experience by the time Satoshi began working on Bitcoin.
The 24-year-old Le Roux produced his first cryptography program in Australia. It was a Windows hard disk encryption program and was distributed as open source software under the name Encryption for the Masses or E4M. With E4M, Le Roux did everything that Satoshi would later do with Bitcoin such as giving support and dealing with bug fixes.
He returned to London around 2000 and worked for a company called Crypto Solutions which produced encryption software to British government and military standards. Crypto Solutions had a relationship with GCHQ which would have given Le Roux access to unpublished NSA algorithms including classified information on the new SHA2 hash algorithm that would be used in Bitcoin.
After Crypto Solutions, Le Roux joined Wilfred Hafner’s SecurStar as Chief Technology Officer. At SecurStar he wrote another whole hard disk encryption program called DriveCrypt Plus Pack. Despite a brilliant start at the company, Le Roux fell out with Hafner who accused him of double dealing. He left SecurStar in late 2002 under a cloud, and began working on a new revolutionary open source disk encryption product that would become TrueCrypt. This probably started as a revenge product against SecurStar. However, he soon made things up with Hafner and the two began to explore an online pill company joint venture. Le Roux no longer had time to work on TrueCrypt and handed it over to other programmers, but remained the driving force behind the project.
Large parts of this have been known for years, other aspects are revealed for the first time in The Satoshi Enigma. Note how Le Roux’s experience seems to closely match what we know about Satoshi. What is really interesting is that le Roux did not just specialise in C++ programming in Windows and cryptography, but also programmed close to the metal. On the fly encryption had to be written below the operating system level which meant assembly. He talked about the fanatical care that went into E4M, “Thousands of hours went into its development and testing…”. The crucial component were the drivers which encrypted and decrypted read/write operations. The space available for these disk drivers on Microsoft compatible machines was tiny:
“… most of the low level code is hand coded assembler, sha1 for example took me 3 months to write, and in the end the full FIPS compliant SHA1 is about 400 bytes. Other bits of the low level code is self-decompressing using a 130 byte lempel ZIV 77 decompressor which also took months to write, and hand optimise the various parameters…”
Le Roux would go on to write more drivers in assembly for DriveCrypt Plus Pack and these found their way into TrueCrypt, much to Hafner’s disgust. It was the drivers that were the “magic source” that was very hard for competitor products to emulate. Le Roux was the type of “paranoid” programmer who would spend three months writing complex code to fit encryption operations into 400 bytes. It is no wonder that his code was viewed as compact and hard to follow.
Hafner summarised his views of Le Roux for Elaine Shannon for her book “Hunting LeRoux”:
“You can find programmers out there like sand on a beach but only a few—less than one percent—with the skills for developing full disk encryption. […] Paul proved to be a brilliant programmer. He is one of the smartest and most consequential technical persons I know. Many people have cool ideas, but Paul also knows or finds a way to transform those ideas into reality.”
A perfect match
To summarise, Le Roux’s experience is a perfect match for Satoshi:
- Satoshi was an expert Windows C++ programmer. Hal Finney thought he must have learnt the language young.
- Le Roux was a C++ expert with fifteen years’ professional experience starting at around age 20.
- Satoshi was an expert at the application of cryptography.
- Le Roux had written multiple encryption products and had even had access to classified information from GCHQ on the SHA2 algorithms used by Bitcoin.
- Satoshi had a highly compact “paranoid” style which some programmers regarded as not meeting the professional standards of the 2000s.
- Le Roux’s programming education was largely informal and he only ever attended one programming course, in the early 1990s. He worked for small outfits, as a self-employed contractor and as an individual open source programmer.
- Satoshi’s dense and unconventional programming style may have come from writing code close to the metal, perhaps as an electronics engineer.
- Le Roux spent considerable time writing drivers in assembly for cryptographic disk operations. This involved writing exceptionally compact code.