aboutsummaryrefslogtreecommitdiff
path: root/include/Encryption.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/Encryption.hpp')
-rw-r--r--include/Encryption.hpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/Encryption.hpp b/include/Encryption.hpp
index b2afe49..4697b35 100644
--- a/include/Encryption.hpp
+++ b/include/Encryption.hpp
@@ -31,8 +31,7 @@ namespace odhtdb
DISABLE_COPY(Encryption)
public:
// Throws EncryptionException on failure (or std::bad_alloc on failed memory allocation)
- Encryption(const DataView &data) : Encryption(data, DataView()) {}
- Encryption(const DataView &data, const DataView &additionalData);
+ Encryption(const DataView &data, const DataView &additionalData = DataView(), const DataView &key = DataView());
~Encryption();
DataView getKey() const;
@@ -49,8 +48,12 @@ namespace odhtdb
{
DISABLE_COPY(Decryption)
public:
+ Decryption() : decryptedText(nullptr), decryptedTextLength(0) {}
+
// Throws DecryptionException on failure
Decryption(const DataView &data, const DataView &nonce, const DataView &key);
+ Decryption(Decryption &&other);
+ Decryption& operator=(Decryption &&other);
~Decryption();
DataView getDecryptedText() const;