23 #ifndef CRYPTO_MANTIS8_h
24 #define CRYPTO_MANTIS8_h
26 #include "BlockCipher.h"
37 bool setKey(
const uint8_t *key,
size_t len);
38 bool setTweak(
const uint8_t *tweak,
size_t len);
42 void encryptBlock(uint8_t *output,
const uint8_t *input);
43 void decryptBlock(uint8_t *output,
const uint8_t *input);
void swapModes()
Swaps the encryption/decryption mode for this Mantis block cipher.
Abstract base class for block ciphers.
bool setKey(const uint8_t *key, size_t len)
Sets the key to use for future encryption and decryption operations.
Mantis-8 tweakable block cipher.
size_t blockSize() const
Size of a Mantis-8 block in bytes.
void decryptBlock(uint8_t *output, const uint8_t *input)
Decrypts a single block using this cipher.
virtual ~Mantis8()
Destroys this Mantis-8 block cipher object after clearing sensitive information.
void encryptBlock(uint8_t *output, const uint8_t *input)
Encrypts a single block using this cipher.
void clear()
Clears all security-sensitive state from this block cipher.
bool setTweak(const uint8_t *tweak, size_t len)
Sets the 64-bit tweak value for this Mantis-8 block cipher.
size_t keySize() const
Size of a Mantis-8 key in bytes.
Mantis8()
Constructs a new Mantis-8 tweakable block cipher instance.