A Boolean Circuit for SHA-256

As part of the implementation of our zero-knowledge contingent service payment protocol, we produced an efficient boolean circuit for SHA-256. The format of our circuit is the same as the one used in the Bristol circuits. The Bristol page does contain a SHA-256 circuit. However, our circuit was optimized to have far fewer AND gates. We share it here as we think it may be useful in general.



  File No. ANDs No. XORs No. INVs
Our circuit sha256Final.txt 22,272  91,780 2,194
Bristol circuit sha-256.txt 90,825 42,029 103,258

Other circuits that may be useful are given below together with their stats. Need a circuit that's not here? Feel free to reach out!

  File No. ANDs No. XORs No. INVs
64 Bit Adder GoldfederAdder64_v2.txt 63  251 0
32 Bit Adder GoldfederAdder32_v2.txt 31  123 0