2015-06-30 00:07:46 +00:00
|
|
|
#ifndef __AES_HPP__
|
|
|
|
#define __AES_HPP__
|
2015-06-29 05:35:25 +00:00
|
|
|
|
|
|
|
#include <stdint.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
#include <memory>
|
|
|
|
|
|
|
|
namespace NOD
|
|
|
|
{
|
|
|
|
|
|
|
|
class IAES
|
|
|
|
{
|
|
|
|
public:
|
2015-07-03 01:57:31 +00:00
|
|
|
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;
|
2015-06-29 05:35:25 +00:00
|
|
|
virtual void setKey(const uint8_t* key)=0;
|
|
|
|
};
|
|
|
|
|
|
|
|
std::unique_ptr<IAES> NewAES();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2015-06-30 00:07:46 +00:00
|
|
|
#endif //__AES_HPP__
|