23NAMESPACE_BEGIN(CryptoPP)
26extern void KeccakF1600(word64 *state);
30 CRYPTOPP_ASSERT(!(input == NULLPTR && length != 0));
31 if (length == 0) {
return; }
34 while (length >= (spaceLeft = r() - m_counter))
37 xorbuf(m_state.
BytePtr() + m_counter, input, spaceLeft);
45 xorbuf(m_state.
BytePtr() + m_counter, input, length);
46 m_counter += (
unsigned int)length;
57 CRYPTOPP_ASSERT(hash != NULLPTR);
60 m_state.
BytePtr()[m_counter] ^= 0x01;
61 m_state.
BytePtr()[r()-1] ^= 0x80;
63 std::memcpy(hash, m_state, size);
void TruncatedFinal(byte *hash, size_t size)
Computes the hash of the current message.
void Restart()
Restart the hash.
void Update(const byte *input, size_t length)
Updates a hash with additional input.
size_type SizeInBytes() const
Provides the number of bytes in the SecBlock.
byte * BytePtr()
Provides a byte pointer to the first element in the memory block.
Classes for Keccak message digests.