The addition of a SHA256Block will give us the flexibility to handle new
workloads that aren't appropriate for SHA1.
As part of this change, let's make the current code templatized so we
can limit as strongly as possible the duplication of code between sha1
and sha256.