10Duke Enterprise C++ Client
|
#include <LibcryptoMessageDigest.h>
Libcrypto-implementation of tenduke::crypto::MessageDigest.
Public Member Functions | |
LibCryptoMessageDigest (const char *algorithmName) | |
Constructs new instance. | |
std::size_t | length () const override |
Returns length (in bytes) of the resulting digest. | |
MessageDigest * | update (const unsigned char *message, std::size_t messageLength) override |
Updates the digest. | |
void | digestTo (unsigned char *digest) override |
Computes the digest to pre-allocated buffer. | |
std::unique_ptr< tenduke::utl::BinaryData > | digest () override |
Computes the digest. | |
Protected Member Functions | |
LibCryptoMessageDigest (const char *algorithmName, const EVP_MD *digest) | |
Constructs new instance. | |
Additional Inherited Members | |
Public Types inherited from tenduke::crypto::MessageDigest | |
enum | Algorithm { NONE , SHA256 } |
Supported algorithms. | |
Static Public Member Functions inherited from tenduke::crypto::MessageDigest | |
static std::string | algorithmToString (enum MessageDigest::Algorithm algorithm) |
Converts algorithm to string representation. | |
static enum MessageDigest::Algorithm | stringToAlgorithm (const std::string &string) |
Converts string to algorithm. | |
static enum MessageDigest::Algorithm | stringToAlgorithm (const char *string) |
Converts string to algorithm. | |
|
explicit |
Constructs new instance.
algorithmName | - |
|
protected |
Constructs new instance.
algorithmName | - |
digest | - |
|
overridevirtual |
Computes the digest.
tenduke::crypto::CryptoException | on error |
Implements tenduke::crypto::MessageDigest.
|
overridevirtual |
Computes the digest to pre-allocated buffer.
messageDigest | the computed digest is placed here (needs to proper size, use MessageDigest::length()). |
tenduke::crypto::CryptoException | on error |
Implements tenduke::crypto::MessageDigest.
|
overridevirtual |
Returns length (in bytes) of the resulting digest.
Implements tenduke::crypto::MessageDigest.
|
overridevirtual |
Updates the digest.
message | - |
messageLength | - |
tenduke::crypto::CryptoException | on error |
Implements tenduke::crypto::MessageDigest.