- Compute an
SHA512hash over the data pointed to by
- Write the first half of the hash to
int64_t util_sha512h ( uint32_t write_ptr, uint32_t write_len, uint32_t read_ptr, uint32_t read_len );
uint8_t hash_out; if (util_sha512h(hash_out, 32, data_in_ptr, data_in_len) < 0) rollback("Could not generate Hash", 23, 1);
Pointer to a buffer the hash will be written to
Length of output buffer, should be at least 32.
Pointer to the buffer data will be read from (to compute the hash over)
Length of input data
The number of bytes written, should always be 32.
If negative, an error: