|
join 1.0
lightweight network framework library
|
class used to manage signature. More...
#include <signature.hpp>


Public Member Functions | |
| Signature (Digest::Algorithm algo) | |
| create instance. | |
| Signature (const Signature &other)=delete | |
| copy constructor. | |
| Signature & | operator= (const Signature &other)=delete |
| copy assignment operator. | |
| Signature (Signature &&other) | |
| move constructor. | |
| Signature & | operator= (Signature &&other) |
| move assignment operator. | |
| virtual | ~Signature ()=default |
| destroy instance. | |
| BytesArray | sign (const std::string &privKey) |
| sign with given private key. | |
| bool | verify (const BytesArray &signature, const std::string &pubKey) |
| verify signature. | |
Static Public Member Functions | |
| static BytesArray | sign (const char *data, std::streamsize size, const std::string &privKey, Digest::Algorithm algo) |
| sign a data with given private key. | |
| static BytesArray | sign (const BytesArray &data, const std::string &privKey, Digest::Algorithm algo) |
| sign a data with given private key. | |
| static BytesArray | sign (const std::string &data, const std::string &privKey, Digest::Algorithm algo) |
| sign a data with given private key. | |
| static bool | verify (const char *data, std::streamsize size, const BytesArray &signature, const std::string &pubKey, Digest::Algorithm algo) |
| verify data signature. | |
| static bool | verify (const BytesArray &data, const BytesArray &signature, const std::string &pubKey, Digest::Algorithm algo) |
| verify data signature. | |
| static bool | verify (const std::string &data, const BytesArray &signature, const std::string &pubKey, Digest::Algorithm algo) |
| verify data signature. | |
class used to manage signature.
| Signature::Signature | ( | Digest::Algorithm | algo | ) |
create instance.
| algo | the message digest used. |
|
delete |
copy constructor.
| other | other object to copy. |
| Signature::Signature | ( | Signature && | other | ) |
move constructor.
| other | other object to move. |
|
virtualdefault |
destroy instance.
copy assignment operator.
| other | other object to assign. |
move assignment operator.
| other | other object to assign. |
|
static |
sign a data with given private key.
| data | data to sign. |
| privKey | path to private key. |
| algo | the algorithm used for the signature. |
|
static |
sign a data with given private key.
| data | data buffer to sign. |
| size | data buffer size. |
| privKey | path to private key. |
| algo | the algorithm used for the signature. |
|
static |
sign a data with given private key.
| data | data to sign. |
| privKey | path to private key. |
| algo | the algorithm used for the signature. |
| BytesArray Signature::sign | ( | const std::string & | privKey | ) |
sign with given private key.
| privKey | path to private key. |
|
static |
verify data signature.
| data | data to verify. |
| signature | the message signature. |
| pubKey | path to public key. |
| algo | the algorithm used for the signature. |
| bool Signature::verify | ( | const BytesArray & | signature, |
| const std::string & | pubKey ) |
verify signature.
| signature | the message signature. |
| pubKey | path to public key. |
|
static |
verify data signature.
| data | data buffer to verify. |
| data | data buffer size to verify. |
| signature | the message signature. |
| pubKey | path to public key. |
| algo | the algorithm used for the signature. |
|
static |
verify data signature.
| data | data to verify. |
| signature | the message signature. |
| pubKey | path to public key. |
| algo | the algorithm used for the signature. |