#include <AsymmetricMessageDigest.h>
Libcrypto-implementation of asymmetric tenduke::crypto::MessageDigestVerifier.
Instance is not thread-safe.
|
| | AsymmetricMessageDigest (const std::string &algorithmName, const LibcryptoPublicKey *verificationKey) |
| | Constructs new instance.
|
| bool | verify (const void *message, std::size_t messageLength, const void *signature, std::size_t signatureLength) override |
| | Verifies the signature.
|
◆ AsymmetricMessageDigest()
| tenduke::crypto::libcrypto::AsymmetricMessageDigest::AsymmetricMessageDigest |
( |
const std::string & | algorithmName, |
|
|
const LibcryptoPublicKey * | verificationKey ) |
Constructs new instance.
- Parameters
-
| algorithmName | name of the message digest agorithm (e.g. sha256) |
| verificationKey | - |
- Exceptions
-
| tenduke::crypto::CryptoException | e.g. if no such agorithm |
◆ verify()
| bool tenduke::crypto::libcrypto::AsymmetricMessageDigest::verify |
( |
const void * | message, |
|
|
std::size_t | messageLength, |
|
|
const void * | signature, |
|
|
std::size_t | signatureLength ) |
|
overridevirtual |
Verifies the signature.
- Parameters
-
| message | - |
| messageLength | - |
| signature | - |
| signatureLength | - |
- Returns
- true if signature verifies
- Exceptions
-
| tenduke::crypto::CryptoException | if libcrypto decides there is something wrong |
Implements tenduke::crypto::MessageDigestVerifier.
The documentation for this class was generated from the following files: