23 #ifndef CRYPTO_BLAKE2B_H
24 #define CRYPTO_BLAKE2B_H
38 void reset(uint8_t outputLength);
39 void reset(
const void *key,
size_t keyLen, uint8_t outputLength = 64);
41 void update(
const void *data,
size_t len);
42 void finalize(
void *hash,
size_t len);
46 void resetHMAC(
const void *key,
size_t keyLen);
47 void finalizeHMAC(
const void *key,
size_t keyLen,
void *hash,
size_t hashLen);
61 void processChunk(uint64_t f0);
void finalize(void *hash, size_t len)
Finalizes the hashing process and returns the hash.
BLAKE2b()
Constructs a BLAKE2b hash object.
static const size_t BLOCK_SIZE
Constant for the block size of BLAKE2b.
void clear()
Clears the hash state, removing all sensitive data, and then resets the hash ready for a new hashing ...
void finalizeHMAC(const void *key, size_t keyLen, void *hash, size_t hashLen)
Finalizes the HMAC hashing process and returns the hash.
size_t hashSize() const
Size of the hash result from finalize().
void update(const void *data, size_t len)
Updates the hash with more data.
size_t blockSize() const
Size of the internal block used by the hash algorithm.
void reset()
Resets the hash ready for a new hashing process.
static const size_t HASH_SIZE
Constant for the size of the hash output of BLAKE2b.
void resetHMAC(const void *key, size_t keyLen)
Resets the hash ready for a new HMAC hashing process.
virtual ~BLAKE2b()
Destroys this BLAKE2b hash object after clearing sensitive information.
Abstract base class for cryptographic hash algorithms.