For one 120-byte SHA-256 prefix, caching by length saves 135 additions and 75 small-sigma calls per message after setup

1 citing publication

We count the SHA-256 operations that can have one cached value on three domains. Each message starts with the bytes 0 through 119 and ends in one or two arbitrary bytes. We fix the order of binary additions. One cache for both lengths leaves 1083 additions, 152 small-sigma calls and 226 large-sigma calls per message. At either fixed length, 948 additions, 77 small-sigma calls and 226 large-sigma calls remain. The difference comes entirely from the final schedule. For N messages at d distinct lengths, a shared cache with separate final schedules saves 135(N - d) additions and 75(N - d) small-sigma calls including setup, compared with one cache for both lengths. A dependency proof certifies each constant site. Valid message pairs certify each variable site. Two trace programs agree on 515 messages. The counts apply to the specified word operations.

SHA-256 · partial evaluation · fixed prefix · message schedule · operation count

No votes to show.

References

7
  1. doi:10.6028/NIST.FIPS.180-4
  2. https://csrc.nist.gov/CSRC/media/Projects/Cryptographic-Standards-and-Guidelines/documents/examples/SHA256.pdf
  3. doi:10.48550/arXiv.1604.00575
  4. https://patents.google.com/patent/EP4710505A1/en
  5. doi:10.1080/02533839.2025.2576145
  6. In a four-suffix SHA-256 test, three-score counts leave the cost per one-bit match between 5.762 and 6.566 compressions
  7. The SHA-256 schedule has binary affine dimension 1744 for all 32-byte messages with FIPS padding

Cited by

1 publication
  1. Equal word values save 130 small-sigma calls across 11 SHA-256 final blocks with lengths below 2^32 bits uses