23 #ifndef CRYPTO_BLAKE2S_H
24 #define CRYPTO_BLAKE2S_H
38 void reset(uint8_t outputLength);
39 void reset(
const void *key,
size_t keyLen, uint8_t outputLength = 32);
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);
60 void processChunk(uint32_t f0);
void clear()
Clears the hash state, removing all sensitive data, and then resets the hash ready for a new hashing ...
size_t blockSize() const
Size of the internal block used by the hash algorithm.
void finalizeHMAC(const void *key, size_t keyLen, void *hash, size_t hashLen)
Finalizes the HMAC hashing process and returns the hash.
virtual ~BLAKE2s()
Destroys this BLAKE2s hash object after clearing sensitive information.
static const size_t HASH_SIZE
Constant for the size of the hash output of BLAKE2s.
BLAKE2s()
Constructs a BLAKE2s hash object.
void finalize(void *hash, size_t len)
Finalizes the hashing process and returns the hash.
void reset()
Resets the hash ready for a new hashing process.
void resetHMAC(const void *key, size_t keyLen)
Resets the hash ready for a new HMAC hashing process.
void update(const void *data, size_t len)
Updates the hash with more data.
size_t hashSize() const
Size of the hash result from finalize().
static const size_t BLOCK_SIZE
Constant for the block size of BLAKE2s.
Abstract base class for cryptographic hash algorithms.