Add a new function to calculate midstate.

This commits add a new function named MidState256 that can be used to
return the internal hashing state after hashing the first chunk
(BlockSize) of data.

ok @marcopeereboom