9 #include <framework/utilities/sha3hash/Hash.h>
10 #include <framework/logging/Logger.h>
13 #include "KeccakHash.h"
53 B2FATAL(
"Unknown mode for SHA3Hash");
69 std::vector<unsigned char> buff(
m_mode);
96 B2FATAL(
"Unknown mode for ShakeHash");
EHashMode m_mode
chosen hash mode
KeccakHashInstance * m_instance
memory structure to calculate the hash value
EHashMode
Available hash modes according to FIPS 202 draft.
@ c_SHA3_512
384bit output size
@ c_SHA3_384
256bit output size
@ c_SHA3_256
224bit output size
EHashMode m_mode
chosen hash mode
KeccakHashInstance * m_instance
memory structure to calculate the hash value
EHashMode
Available hash modes according to FIPS 202 draft.
@ c_SHAKE128
variable hash size with up to 128 bit collision resistance
@ c_SHAKE256
variable hash size with up to 256 bit collision resistance
~SHA3Hash()
destructor freeing the memory
void update(int n, unsigned char *buff)
update the internal state by adding n bytes of data from buff
void getHash(int n, unsigned char *buff)
obtain the hash value with a length of n bytes into buff
SHA3Hash(EHashMode length)
Constructor initializing the hash structure with a given output size.
~ShakeHash()
destructor freeing the memory
void clear()
reinit the hash structure to create a new hash sum
std::vector< unsigned char > getHash()
obtain the hash value as a vector of unsigned char
ShakeHash(EHashMode mode)
constructor initializing the hash structure
Abstract base class for different kinds of events.
Since we cannot forward declare the memory structure directly due to some typedeffing we inherit from...