libdecaf
Loading...
Searching...
No Matches
Public Member Functions | List of all members
decaf::KeccakHash Class Reference

Hash function derived from Keccak FUTURE: throw ProtocolException when hash is misused by calling update() after output(). More...

#include <shake.hxx>

Inheritance diagram for decaf::KeccakHash:
decaf::SHAKE< 256 > decaf::SHA3< bits > decaf::SHAKE< bits > decaf::EdDSA< Ed448Goldilocks >::Prehash

Public Member Functions

void update (const uint8_t *__restrict__ in, size_t len) DECAF_NOEXCEPT
 Add more data to running hash.
 
void update (const Block &s) DECAF_NOEXCEPT
 Add more data to running hash, C++ version.
 
KeccakHashoperator<< (const Block &s) DECAF_NOEXCEPT
 Add more data, stream version.
 
KeccakHashoperator+= (const Block &s) DECAF_NOEXCEPT
 Same as <<.
 
SecureBuffer output (size_t len)
 Output bytes from the sponge.
 
SecureBuffer final (size_t len)
 Output bytes from the sponge.
 
void output (Buffer b)
 Output bytes from the sponge.
 
void final (Buffer b)
 Output bytes from the sponge and reinitialize it.
 
size_t default_output_size () const DECAF_NOEXCEPT
 Return the sponge's default output size.
 
size_t max_output_size () const DECAF_NOEXCEPT
 Return the sponge's maximum output size.
 
SecureBuffer output ()
 Output the default number of bytes.
 
SecureBuffer final ()
 Output the default number of bytes, and reset hash.
 
void reset () DECAF_NOEXCEPT
 Reset the hash to the empty string.
 
 ~KeccakHash () DECAF_NOEXCEPT
 Destructor zeroizes state.
 

Detailed Description

Hash function derived from Keccak FUTURE: throw ProtocolException when hash is misused by calling update() after output().

Member Function Documentation

◆ final()

void decaf::KeccakHash::final ( Buffer  b)
inline

Output bytes from the sponge and reinitialize it.

Throw LengthException if you've output too many bytes from a SHA3 instance.

◆ output()

void decaf::KeccakHash::output ( Buffer  b)
inline

Output bytes from the sponge.

Throw LengthException if you've output too many bytes from a SHA-3 instance.


The documentation for this class was generated from the following file: