Kea 2.7.6
|
#include <crypto_hash.h>
Public Member Functions | |
~Hash () | |
Destructor. | |
void | final (isc::util::OutputBuffer &result, size_t len) |
Calculate the final digest. | |
std::vector< uint8_t > | final (size_t len) |
Calculate the final digest. | |
void | final (void *result, size_t len) |
Calculate the final digest. | |
HashAlgorithm | getHashAlgorithm () const |
Returns the HashAlgorithm of the object. | |
size_t | getOutputLength () const |
Returns the output size of the digest. | |
void | update (const void *data, const size_t len) |
Add data to digest. | |
Friends | |
Hash * | CryptoLink::createHash (const HashAlgorithm) |
Hash support.
This class is used to create Hash digests. Instances can be created with CryptoLink::createHash()
Definition at line 27 of file crypto_hash.h.
isc::cryptolink::Hash::~Hash | ( | ) |
Destructor.
Definition at line 160 of file botan_hash.cc.
void isc::cryptolink::Hash::final | ( | isc::util::OutputBuffer & | result, |
size_t | len ) |
Calculate the final digest.
The result will be appended to the given outputbuffer
LibraryError | if there was any unexpected exception in the underlying library |
result | The OutputBuffer to append the result to |
len | The number of bytes from the result to copy. If this value is smaller than the algorithms output size, the result will be truncated. If this value is larger, only output size bytes will be copied |
Definition at line 180 of file botan_hash.cc.
References isc::cryptolink::HashImpl::final().
std::vector< uint8_t > isc::cryptolink::Hash::final | ( | size_t | len | ) |
Calculate the final digest.
The result will be returned as a std::vector<uint8_t>
LibraryError | if there was any unexpected exception in the underlying library |
len | The number of bytes from the result to copy. If this value is smaller than the algorithms output size, the result will be truncated. If this value is larger, only output size bytes will be copied |
Definition at line 190 of file botan_hash.cc.
References isc::cryptolink::HashImpl::final().
void isc::cryptolink::Hash::final | ( | void * | result, |
size_t | len ) |
Calculate the final digest.
len bytes of data from the result will be copied to *result If len is larger than the output size, only output_size bytes will be copied. If it is smaller, the output will be truncated
LibraryError | if there was any unexpected exception in the underlying library |
At least len bytes of data must be available for writing at result.
result | The memory location the digest will be written to |
len | Specifies the size of the result location available |
Definition at line 185 of file botan_hash.cc.
References isc::cryptolink::HashImpl::final().
HashAlgorithm isc::cryptolink::Hash::getHashAlgorithm | ( | ) | const |
Returns the HashAlgorithm of the object.
Definition at line 165 of file botan_hash.cc.
References isc::cryptolink::HashImpl::getHashAlgorithm().
size_t isc::cryptolink::Hash::getOutputLength | ( | ) | const |
Returns the output size of the digest.
Definition at line 170 of file botan_hash.cc.
References isc::cryptolink::HashImpl::getOutputLength().
void isc::cryptolink::Hash::update | ( | const void * | data, |
const size_t | len ) |
Add data to digest.
LibraryError | if there was any unexpected exception in the underlying library |
data | The data to add |
len | The size of the data |
Definition at line 175 of file botan_hash.cc.
References isc::cryptolink::HashImpl::update().
|
friend |