14#ifndef CRYPTOPP_KALYNA_H
15#define CRYPTOPP_KALYNA_H
27 static const char* StaticAlgorithmName()
38 static const char* StaticAlgorithmName()
49 static const char* StaticAlgorithmName()
65 mutable AlignedSecBlock64 m_wspace;
66 AlignedSecBlock64 m_mkey;
67 AlignedSecBlock64 m_rkeys;
68 unsigned int m_kl, m_nb, m_nk;
92 return std::string(
"Kalyna-128") +
"(" +
IntToString(m_kl*8) +
")";
103 void UncheckedSetKey(
const byte *key,
unsigned int keylen,
const NameValuePairs ¶ms);
104 void ProcessAndXorBlock(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
107 void SetKey_22(
const word64 key[2]);
108 void SetKey_24(
const word64 key[4]);
109 void ProcessBlock_22(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
110 void ProcessBlock_24(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
138 return std::string(
"Kalyna-256") +
"(" +
IntToString(m_kl*8) +
")";
149 void UncheckedSetKey(
const byte *key,
unsigned int keylen,
const NameValuePairs ¶ms);
150 void ProcessAndXorBlock(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
153 void SetKey_44(
const word64 key[4]);
154 void SetKey_48(
const word64 key[8]);
155 void ProcessBlock_44(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
156 void ProcessBlock_48(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
184 return std::string(
"Kalyna-512") +
"(" +
IntToString(m_kl*8) +
")";
195 void UncheckedSetKey(
const byte *key,
unsigned int keylen,
const NameValuePairs ¶ms);
196 void ProcessAndXorBlock(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
199 void SetKey_88(
const word64 key[8]);
200 void ProcessBlock_88(
const byte *inBlock,
const byte *xorBlock,
byte *outBlock)
const;
207typedef Kalyna128::Encryption Kalyna128Encryption;
208typedef Kalyna128::Decryption Kalyna128Decryption;
210typedef Kalyna256::Encryption Kalyna256Encryption;
211typedef Kalyna256::Decryption Kalyna256Decryption;
213typedef Kalyna512::Encryption Kalyna512Encryption;
214typedef Kalyna512::Decryption Kalyna512Decryption;
Provides class member functions to key a block cipher.
Provides a base implementation of Algorithm and SimpleKeyingInterface for block ciphers.
Inherited by algorithms with fixed block size.
Inherited by keyed algorithms with fixed key length.
unsigned int OptimalDataAlignment() const
Provides input and output data alignment for optimal performance.
std::string AlgorithmName() const
Provides the name of this algorithm.
Kalyna 128-bit block cipher.
unsigned int OptimalDataAlignment() const
Provides input and output data alignment for optimal performance.
std::string AlgorithmName() const
Provides the name of this algorithm.
Kalyna 256-bit block cipher.
std::string AlgorithmName() const
Provides the name of this algorithm.
unsigned int OptimalDataAlignment() const
Provides input and output data alignment for optimal performance.
Kalyna 512-bit block cipher.
Kalyna block cipher base class.
Interface for retrieving values given their names.
Secure memory block with allocator and cleanup.
Inherited by keyed algorithms with variable key length.
Library configuration file.
unsigned long long word64
64-bit unsigned datatype
std::string IntToString(T value, unsigned int base=10)
Converts a value to a string.
unsigned int GetAlignmentOf()
Returns the minimum alignment requirements of a type.
Crypto++ library namespace.
Classes and functions for secure memory allocations.
Classes and functions for implementing secret key algorithms.
Provides Encryption and Decryption typedefs used by derived classes to implement a block cipher.
Kalyna-128 block cipher information.
Kalyna-256 block cipher information.
Kalyna-512 block cipher information.