Automatic Formal Verification of Block Cipher Implementations

Eric Smith, David L. Dill
2008 2008 Formal Methods in Computer-Aided Design  
This paper describes an automatic method for proving equivalence of implementations of block ciphers (and similar cryptographic algorithms). The method can compare two object code implementations or compare object code to a formal, mathematical specification. In either case it proves that the computations being compared are bit-for-bit equivalent. The method has two steps. First the computations are represented as large mathematical terms. Then the two terms are proved equivalent using a phased
more » ... lent using a phased approach that includes domain-specific optimizations for block ciphers and relies on a careful choice of both word-level and bit-level simplifications. The verification also relies on STP [5], a SAT-based decision procedure for bit-vectors and arrays. The method has been applied to verify real, widely-used Java code from Sun Microsystems and the open source Bouncy Castle project. It has been applied to implementations of the block ciphers AES, DES, Triple DES (3DES), Blowfish, RC2, RC6, and Skipjack as well as applications of the cryptographic hash functions SHA-1 and MD5 on fixedlength messages. 978-1-4244-2735-2/08/$25.00 ©2008 IEEE
doi:10.1109/fmcad.2008.ecp.10 dblp:conf/fmcad/SmithD08 fatcat:hzpzzutmznaspoq4fri7cakjqu