#include <crypto.h>
Inheritance diagram for Encrypt_Base:
Public Member Functions | |
Encrypt_Base () | |
virtual | ~Encrypt_Base () |
bool | SetKey (DataChunk &Key) |
Set an encryption key. | |
bool | SetKey (DataChunkPtr &Key) |
Set an encryption key. | |
virtual bool | SetKey (size_t KeySize, const UInt8 *Key)=0 |
Set an encryption key. | |
virtual bool | SetIV (size_t IVSize, const UInt8 *IV, bool Force=false)=0 |
Set an encryption Initialization Vector. | |
bool | SetIV (DataChunk &IV, bool Force=false) |
Set an encryption Initialization Vector. | |
bool | SetIV (DataChunkPtr &IV, bool Force=false) |
Set an encryption Initialization Vector. | |
virtual DataChunkPtr | GetIV (void)=0 |
Get the Initialization Vector that will be used for the next encryption. | |
virtual bool | CanEncryptInPlace (size_t BlockSize=0)=0 |
Can this encryption system safely encrypt in place? | |
virtual bool | EncryptInPlace (size_t Size, UInt8 *Data)=0 |
Encrypt data bytes in place. | |
bool | EncryptInPlace (DataChunk &Data) |
Encrypt data bytes in place. | |
bool | EncryptInPlace (DataChunkPtr &Data) |
Encrypt data bytes in place. | |
virtual DataChunkPtr | Encrypt (size_t Size, const UInt8 *Data)=0 |
Encrypt data and return in a new buffer. | |
DataChunkPtr | Encrypt (DataChunk &Data) |
Encrypt data and return in a new buffer. | |
DataChunkPtr | Encrypt (DataChunkPtr &Data) |
Encrypt data and return in a new buffer. |
Encrypt_Base | ( | ) | [inline] |
virtual ~Encrypt_Base | ( | ) | [inline, virtual] |
bool SetKey | ( | DataChunk & | Key | ) | [inline] |
Set an encryption key.
bool SetKey | ( | DataChunkPtr & | Key | ) | [inline] |
Set an encryption key.
virtual bool SetKey | ( | size_t | KeySize, | |
const UInt8 * | Key | |||
) | [pure virtual] |
virtual bool SetIV | ( | size_t | IVSize, | |
const UInt8 * | IV, | |||
bool | Force = false | |||
) | [pure virtual] |
Set an encryption Initialization Vector.
Implemented in AESEncrypt.
bool SetIV | ( | DataChunk & | IV, | |
bool | Force = false | |||
) | [inline] |
Set an encryption Initialization Vector.
bool SetIV | ( | DataChunkPtr & | IV, | |
bool | Force = false | |||
) | [inline] |
Set an encryption Initialization Vector.
virtual DataChunkPtr GetIV | ( | void | ) | [pure virtual] |
Get the Initialization Vector that will be used for the next encryption.
If called immediately after SetIV() with Force=true or SetIV() for a crypto scheme that accepts each offered vector (rather than creating its own ones) the result will be the vector offered in that SetIV() call.
Implemented in AESEncrypt.
virtual bool CanEncryptInPlace | ( | size_t | BlockSize = 0 |
) | [pure virtual] |
Can this encryption system safely encrypt in place?
If BlockSize is 0 this function will return true if encryption of all block sizes can be "in place". Otherwise the result will indicate whether the given blocksize can be encrypted "in place".
Implemented in AESEncrypt.
virtual bool EncryptInPlace | ( | size_t | Size, | |
UInt8 * | Data | |||
) | [pure virtual] |
Encrypt data bytes in place.
Implemented in AESEncrypt.
bool EncryptInPlace | ( | DataChunk & | Data | ) | [inline] |
Encrypt data bytes in place.
bool EncryptInPlace | ( | DataChunkPtr & | Data | ) | [inline] |
Encrypt data bytes in place.
virtual DataChunkPtr Encrypt | ( | size_t | Size, | |
const UInt8 * | Data | |||
) | [pure virtual] |
Encrypt data and return in a new buffer.
Implemented in AESEncrypt.
DataChunkPtr Encrypt | ( | DataChunk & | Data | ) | [inline] |
Encrypt data and return in a new buffer.
DataChunkPtr Encrypt | ( | DataChunkPtr & | Data | ) | [inline] |
Encrypt data and return in a new buffer.