Enigma 3.2.2
A Simple, Reliable and Efficient Encryption Tool
Loading...
Searching...
No Matches
TripleDES.hpp
Go to the documentation of this file.
1#pragma once
3
13class TripleDES : public Algorithm {
14 public:
18 explicit TripleDES(const Algorithm::Intent intent) noexcept;
19 ~TripleDES() noexcept override;
20
21 public:
22 std::vector<byte> Encrypt(const std::string& password, const byte *buffer, const std::size_t buffSize) override;
23 std::vector<byte> Encrypt(const std::string& password, const std::vector<byte>& buffer) override;
24 std::vector<byte> Decrypt(const std::string& password, const byte *cipher, const std::size_t cipherSize) override;
25 std::vector<byte> Decrypt(const std::string& password, const std::vector<byte>& cipher) override;
26 void Encrypt(const std::string& password, const fs::path& in_filename, const fs::path& out_filename) override;
27 void Decrypt(const std::string& password, const fs::path& in_filename, const fs::path& out_filename) override;
28
29 private:
30 std::unique_ptr<CryptoPP::EAX<CryptoPP::DES_EDE3>::Encryption> m_tripledes_encryptor;
31 std::unique_ptr<CryptoPP::EAX<CryptoPP::DES_EDE3>::Decryption> m_tripledes_decryptor;
32};
33
#define NS_ENIGMA_BEGIN
Enable/Disable Assertions.
Definition Macros.hpp:13
#define NS_ENIGMA_END
Definition Macros.hpp:14
Algorithm abstract class.
Definition Algorithm.hpp:53
~TripleDES() noexcept override
TripleDES(const Algorithm::Intent intent) noexcept