Practical Cryptography

Niels Ferguson and Bruce Schneier

book cover

This book collects our combined experiences on how to design cryptographic systems the right way.

There is a huge difference between cryptography as a mathematical science and cryptography as an engineering discipline. Mathematicians are concerned with making nice abstract designs that work well in theory. The engineers actually have to build secure systems.

This book is for the people who design and build systems. It is the book we wish we'd had more than a decade ago when we started our cryptographic careers. It not only explains how to select the right cryptographic primitives, but also how to build a secure system with them. This involves far more than just cryptography. There are a large number of important factors that are often neglected: proper design criteria, software quality, revocation, system complexity, entropy, storing secrets, wiping secrets, side-channels, key management, etc. All these details make the difference between a cryptographic toy and a real secure system, and they must therefore be taken into account by anyone building such a system. We didn't know of any book that contained the necessary information, so we decided to write it ourselves.

While writing the book we also found some new insights. We give an improved definition for the security of a block cipher that is much more useful for the system designer than the traditional ones. We explain a little-known technique for making sure that complex large-integer libraries do not undermine the security of the rest of the system. Probably the most important new design in the book is Fortuna: a PRNG that is a significant improvement on any existing PRNG.