athena/include/aes.hpp

20 lines
439 B
C++
Raw Permalink Normal View History

2018-10-07 03:37:09 +00:00
#pragma once
2017-12-29 07:55:42 +00:00
#include <cstdint>
#include <cstdlib>
#include <memory>
2018-12-08 05:18:17 +00:00
namespace athena {
2018-12-08 05:18:17 +00:00
class IAES {
public:
2018-12-08 05:18:17 +00:00
virtual ~IAES() {}
virtual void encrypt(const uint8_t* iv, const uint8_t* inbuf, uint8_t* outbuf, uint64_t len) = 0;
virtual void decrypt(const uint8_t* iv, const uint8_t* inbuf, uint8_t* outbuf, uint64_t len) = 0;
virtual void setKey(const uint8_t* key) = 0;
};
std::unique_ptr<IAES> NewAES();
2018-12-08 05:18:17 +00:00
} // namespace athena