Disk ARchive
2.7.15
Full featured and portable backup and archiving tool
|
asymetric ciphering More...
#include <crypto_asym.hpp>
Public Member Functions | |
crypto_asym (const std::shared_ptr< user_interaction > &ui) | |
general use constructor | |
crypto_asym (const crypto_asym &ref)=delete | |
disabling copy constructor | |
crypto_asym (crypto_asym &&ref)=delete | |
disabling move constuctor | |
crypto_asym & | operator= (const crypto_asym &ref)=delete |
disabling object assignment | |
crypto_asym & | operator= (crypto_asym &&ref)=delete |
disabling move assignment operator | |
~crypto_asym () | |
the destructor | |
void | set_signatories (const std::vector< std::string > &signatories) |
defines the list of email or keyid which associated key will be used for signing | |
void | encrypt (const std::vector< std::string > &recipients_email, generic_file &clear, generic_file &ciphered) |
encrypt (and sign if signatures have been given using set_signatories) data for the given recipients More... | |
void | decrypt (generic_file &ciphered, generic_file &clear) |
un-cipher data More... | |
const std::list< signator > & | verify () const |
user_interaction & | get_ui () const |
exposing to public visibility the protected method of mem_ui More... | |
Public Member Functions inherited from libdar::mem_ui | |
mem_ui (const std::shared_ptr< user_interaction > &dialog) | |
constructor More... | |
mem_ui (const mem_ui &ref)=default | |
the copy constructor More... | |
mem_ui (mem_ui &&ref) noexcept=default | |
the move constructor | |
mem_ui & | operator= (const mem_ui &ref)=default |
assignement operator More... | |
mem_ui & | operator= (mem_ui &&ref) noexcept=default |
move operator | |
virtual | ~mem_ui () noexcept(false) |
destructor More... | |
Private Member Functions | |
void | release_context () |
void | build_context () |
Private Attributes | |
bool | has_signatories |
std::list< signator > | signing_result |
Additional Inherited Members | |
Protected Member Functions inherited from libdar::mem_ui | |
user_interaction & | get_ui () const |
get access to the user_interaction object More... | |
std::shared_ptr< user_interaction > | get_pointer () const |
get access to the shared_ptr pointing to the user_interaction | |
asymetric ciphering
Definition at line 50 of file crypto_asym.hpp.
void libdar::crypto_asym::decrypt | ( | generic_file & | ciphered, |
generic_file & | clear | ||
) |
un-cipher data
[in] | ciphered | contains the encrypted data to decipher |
[out] | clear | resulting un-ciphered (thus clear) data (the object must be readable) |
void libdar::crypto_asym::encrypt | ( | const std::vector< std::string > & | recipients_email, |
generic_file & | clear, | ||
generic_file & | ciphered | ||
) |
encrypt (and sign if signatures have been given using set_signatories) data for the given recipients
[in] | recipients_email | list of email or keyid of recipient that will be able to read the encrypted data |
[in] | clear | where to read from clear data to be encrypted (the object must be readable) |
[out] | ciphered | where to write down encrypted data (the object must be writable) |
|
inline |
exposing to public visibility the protected method of mem_ui
used to provide access to the user_interaction from the callback function required by gpgme_set_passphrase_cb().
Definition at line 99 of file crypto_asym.hpp.
References libdar::mem_ui::get_ui().
|
inline |
after un-ciphering data retrieve the list of signature that were used beside encryption return a sorted list of signatories
Definition at line 93 of file crypto_asym.hpp.