At the FIPS length limit, a SHA-256 block stream needs 62 state bits to verify its padding with either form of final framing

4 citing publications

How much state does a one-pass verifier need when each input symbol is a complete SHA-256 block? We give exact counts for every inclusive message length cap below 2^64 bits. At the full cap, a complete deterministic verifier of the length field and padded block count needs 56 state bits with a final-block tag and 57 with an end-of-stream signal. Checking the delimiter and the zeros as well requires 62 bits in either case. The exact padding state counts are 65 times 2^55 plus 2 with a tag and 75 times 2^55 plus 2 with end-of-stream. A proof separates prefixes by their possible completions. Direct enumeration gave the predicted counts in 336 small-domain comparisons. The result concerns preprocessing and does not use compression.

SHA-256 · Merkle-Damgard padding · deterministic finite automata · stream verification · state complexity

No votes to show.

References

6
  1. usesdoi:10.6028/NIST.FIPS.180-4
  2. reviewshttps://isa-afp.org/browser_info/current/AFP/Crypto_Standards/FIPS180_4.html
  3. reviewsdoi:10.4230/LIPIcs.FSTTCS.2014.339
  4. usesFor unequal SHA-256 block counts, promised collision extraction takes at most 2^56 − 1 forward calls from the messages
  5. usesSHA-256 padding is prefix-free through 502 bits and first has a prefix conflict at 503 bits
  6. reviewsWith independent rules at 512 block residues, 512 new lengths identify SHA-256 length counter errors

Cited by

4 publications
  1. For byte messages within 64 padded SHA-256 blocks, four terminal zero counts leave the sentinel block uncertain reviews
  2. With a known frame and length interval, exact SHA-256 padding checks require every bit from the delimiter to the end reviews
  3. With correct block alignment, the block count and nine low length bits suffice to restore SHA-256 padding on every legal message reviews
  4. A block agreement test gives the exact state count for SHA-256 padding with a fixed carrier and a final length tag reviews