Add CRYPTOPP_STATIC_CONSTEXPR macro
parent
5be05bce07
commit
76b11b010c
2
3way.h
2
3way.h
|
|
@ -16,7 +16,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief ThreeWay block cipher information
|
//! \brief ThreeWay block cipher information
|
||||||
struct ThreeWay_Info : public FixedBlockSize<12>, public FixedKeyLength<12>, public VariableRounds<11>
|
struct ThreeWay_Info : public FixedBlockSize<12>, public FixedKeyLength<12>, public VariableRounds<11>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "3-Way";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "3-Way";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class ThreeWay
|
//! \class ThreeWay
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ public:
|
||||||
void Update(const byte *input, size_t length);
|
void Update(const byte *input, size_t length);
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
unsigned int DigestSize() const {return DIGESTSIZE;}
|
unsigned int DigestSize() const {return DIGESTSIZE;}
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Adler32";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Adler32";}
|
||||||
std::string AlgorithmName() const {return StaticAlgorithmName();}
|
std::string AlgorithmName() const {return StaticAlgorithmName();}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
||||||
4
arc4.h
4
arc4.h
|
|
@ -24,7 +24,7 @@ class CRYPTOPP_NO_VTABLE ARC4_Base : public VariableKeyLength<16, 1, 256>, publi
|
||||||
public:
|
public:
|
||||||
~ARC4_Base();
|
~ARC4_Base();
|
||||||
|
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "ARC4";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "ARC4";}
|
||||||
|
|
||||||
void GenerateBlock(byte *output, size_t size);
|
void GenerateBlock(byte *output, size_t size);
|
||||||
void DiscardBytes(size_t n);
|
void DiscardBytes(size_t n);
|
||||||
|
|
@ -59,7 +59,7 @@ DOCUMENTED_TYPEDEF(SymmetricCipherFinal<ARC4_Base>, ARC4)
|
||||||
class CRYPTOPP_NO_VTABLE MARC4_Base : public ARC4_Base
|
class CRYPTOPP_NO_VTABLE MARC4_Base : public ARC4_Base
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "MARC4";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "MARC4";}
|
||||||
|
|
||||||
typedef SymmetricCipherFinal<MARC4_Base> Encryption;
|
typedef SymmetricCipherFinal<MARC4_Base> Encryption;
|
||||||
typedef SymmetricCipherFinal<MARC4_Base> Decryption;
|
typedef SymmetricCipherFinal<MARC4_Base> Decryption;
|
||||||
|
|
|
||||||
4
blake2.h
4
blake2.h
|
|
@ -41,7 +41,7 @@ struct BLAKE2_Info : public VariableKeyLength<(T_64bit ? 64 : 32),0,(T_64bit ? 6
|
||||||
CRYPTOPP_CONSTANT(SALTSIZE = (T_64bit ? 16 : 8))
|
CRYPTOPP_CONSTANT(SALTSIZE = (T_64bit ? 16 : 8))
|
||||||
CRYPTOPP_CONSTANT(PERSONALIZATIONSIZE = (T_64bit ? 16 : 8))
|
CRYPTOPP_CONSTANT(PERSONALIZATIONSIZE = (T_64bit ? 16 : 8))
|
||||||
|
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return (T_64bit ? "BLAKE2b" : "BLAKE2s");}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return (T_64bit ? "BLAKE2b" : "BLAKE2s");}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class BLAKE2_ParameterBlock
|
//! \class BLAKE2_ParameterBlock
|
||||||
|
|
@ -180,7 +180,7 @@ public:
|
||||||
|
|
||||||
//! \brief Retrieve the static algorithm name
|
//! \brief Retrieve the static algorithm name
|
||||||
//! \returns the algorithm name (BLAKE2s or BLAKE2b)
|
//! \returns the algorithm name (BLAKE2s or BLAKE2b)
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return BLAKE2_Info<T_64bit>::StaticAlgorithmName();}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return BLAKE2_Info<T_64bit>::StaticAlgorithmName();}
|
||||||
|
|
||||||
//! \brief Retrieve the object's name
|
//! \brief Retrieve the object's name
|
||||||
//! \returns the object's algorithm name following RFC 7693
|
//! \returns the object's algorithm name following RFC 7693
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief Blowfish block cipher information
|
//! \brief Blowfish block cipher information
|
||||||
struct Blowfish_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 4, 56>, public FixedRounds<16>
|
struct Blowfish_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 4, 56>, public FixedRounds<16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Blowfish";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Blowfish";}
|
||||||
};
|
};
|
||||||
|
|
||||||
// <a href="http://www.weidai.com/scan-mirror/cs.html#Blowfish">Blowfish</a>
|
// <a href="http://www.weidai.com/scan-mirror/cs.html#Blowfish">Blowfish</a>
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief Camellia block cipher information
|
//! \brief Camellia block cipher information
|
||||||
struct Camellia_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>
|
struct Camellia_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Camellia";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Camellia";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class Camellia
|
//! \class Camellia
|
||||||
|
|
|
||||||
4
cast.h
4
cast.h
|
|
@ -23,7 +23,7 @@ protected:
|
||||||
//! \brief CAST128 block cipher information
|
//! \brief CAST128 block cipher information
|
||||||
struct CAST128_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 5, 16>
|
struct CAST128_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 5, 16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "CAST-128";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "CAST-128";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class CAST128
|
//! \class CAST128
|
||||||
|
|
@ -68,7 +68,7 @@ public:
|
||||||
//! \brief CAST256 block cipher information
|
//! \brief CAST256 block cipher information
|
||||||
struct CAST256_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 4>
|
struct CAST256_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 4>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "CAST-256";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "CAST-256";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class CAST256
|
//! \class CAST256
|
||||||
|
|
|
||||||
2
chacha.h
2
chacha.h
|
|
@ -25,7 +25,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
template <unsigned int R>
|
template <unsigned int R>
|
||||||
struct ChaCha_Info : public VariableKeyLength<32, 16, 32, 16, SimpleKeyingInterface::UNIQUE_IV, 8>, public FixedRounds<R>
|
struct ChaCha_Info : public VariableKeyLength<32, 16, 32, 16, SimpleKeyingInterface::UNIQUE_IV, 8>, public FixedRounds<R>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {
|
||||||
return (R==8?"ChaCha8":(R==12?"ChaCha12":(R==20?"ChaCha20":"ChaCha")));
|
return (R==8?"ChaCha8":(R==12?"ChaCha12":(R==20?"ChaCha20":"ChaCha")));
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -936,6 +936,7 @@ NAMESPACE_END
|
||||||
#endif // CRYPTOPP_CXX11_ALIGNAS
|
#endif // CRYPTOPP_CXX11_ALIGNAS
|
||||||
|
|
||||||
// Hack... CRYPTOPP_CONSTANT is defined earlier, before C++11 constexpr availability is determined
|
// Hack... CRYPTOPP_CONSTANT is defined earlier, before C++11 constexpr availability is determined
|
||||||
|
// http://stackoverflow.com/q/35213098/608639
|
||||||
#if defined(CRYPTOPP_CXX11_CONSTEXPR)
|
#if defined(CRYPTOPP_CXX11_CONSTEXPR)
|
||||||
# undef CRYPTOPP_CONSTANT
|
# undef CRYPTOPP_CONSTANT
|
||||||
# define CRYPTOPP_CONSTANT(x) constexpr static int x;
|
# define CRYPTOPP_CONSTANT(x) constexpr static int x;
|
||||||
|
|
|
||||||
1
config.h
1
config.h
|
|
@ -936,6 +936,7 @@ NAMESPACE_END
|
||||||
#endif // CRYPTOPP_CXX11_ALIGNAS
|
#endif // CRYPTOPP_CXX11_ALIGNAS
|
||||||
|
|
||||||
// Hack... CRYPTOPP_CONSTANT is defined earlier, before C++11 constexpr availability is determined
|
// Hack... CRYPTOPP_CONSTANT is defined earlier, before C++11 constexpr availability is determined
|
||||||
|
// http://stackoverflow.com/q/35213098/608639
|
||||||
#if defined(CRYPTOPP_CXX11_CONSTEXPR)
|
#if defined(CRYPTOPP_CXX11_CONSTEXPR)
|
||||||
# undef CRYPTOPP_CONSTANT
|
# undef CRYPTOPP_CONSTANT
|
||||||
# define CRYPTOPP_CONSTANT(x) constexpr static int x;
|
# define CRYPTOPP_CONSTANT(x) constexpr static int x;
|
||||||
|
|
|
||||||
4
crc.h
4
crc.h
|
|
@ -31,7 +31,7 @@ public:
|
||||||
void Update(const byte *input, size_t length);
|
void Update(const byte *input, size_t length);
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
unsigned int DigestSize() const {return DIGESTSIZE;}
|
unsigned int DigestSize() const {return DIGESTSIZE;}
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "CRC32";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "CRC32";}
|
||||||
std::string AlgorithmName() const {return StaticAlgorithmName();}
|
std::string AlgorithmName() const {return StaticAlgorithmName();}
|
||||||
|
|
||||||
void UpdateByte(byte b) {m_crc = m_tab[CRC32_INDEX(m_crc) ^ b] ^ CRC32_SHIFTED(m_crc);}
|
void UpdateByte(byte b) {m_crc = m_tab[CRC32_INDEX(m_crc) ^ b] ^ CRC32_SHIFTED(m_crc);}
|
||||||
|
|
@ -56,7 +56,7 @@ public:
|
||||||
void Update(const byte *input, size_t length);
|
void Update(const byte *input, size_t length);
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
unsigned int DigestSize() const {return DIGESTSIZE;}
|
unsigned int DigestSize() const {return DIGESTSIZE;}
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "CRC32C";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "CRC32C";}
|
||||||
std::string AlgorithmName() const {return StaticAlgorithmName();}
|
std::string AlgorithmName() const {return StaticAlgorithmName();}
|
||||||
|
|
||||||
void UpdateByte(byte b) {m_crc = m_tab[CRC32_INDEX(m_crc) ^ b] ^ CRC32_SHIFTED(m_crc);}
|
void UpdateByte(byte b) {m_crc = m_tab[CRC32_INDEX(m_crc) ^ b] ^ CRC32_SHIFTED(m_crc);}
|
||||||
|
|
|
||||||
4
des.h
4
des.h
|
|
@ -30,7 +30,7 @@ protected:
|
||||||
struct DES_Info : public FixedBlockSize<8>, public FixedKeyLength<8>
|
struct DES_Info : public FixedBlockSize<8>, public FixedKeyLength<8>
|
||||||
{
|
{
|
||||||
// disable DES in DLL version by not exporting this function
|
// disable DES in DLL version by not exporting this function
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "DES";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "DES";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class DES
|
//! \class DES
|
||||||
|
|
@ -125,7 +125,7 @@ public:
|
||||||
//! \brief DESX block cipher information
|
//! \brief DESX block cipher information
|
||||||
struct DES_XEX3_Info : public FixedBlockSize<8>, public FixedKeyLength<24>
|
struct DES_XEX3_Info : public FixedBlockSize<8>, public FixedKeyLength<24>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "DES-XEX3";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "DES-XEX3";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class DES_XEX3
|
//! \class DES_XEX3
|
||||||
|
|
|
||||||
|
|
@ -309,7 +309,7 @@ template <class EC>
|
||||||
class DL_Algorithm_ECDSA : public DL_Algorithm_GDSA<typename EC::Point>
|
class DL_Algorithm_ECDSA : public DL_Algorithm_GDSA<typename EC::Point>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "ECDSA";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "ECDSA";}
|
||||||
|
|
||||||
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
||||||
virtual ~DL_Algorithm_ECDSA() {}
|
virtual ~DL_Algorithm_ECDSA() {}
|
||||||
|
|
@ -323,7 +323,7 @@ template <class EC>
|
||||||
class DL_Algorithm_ECNR : public DL_Algorithm_NR<typename EC::Point>
|
class DL_Algorithm_ECNR : public DL_Algorithm_NR<typename EC::Point>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "ECNR";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "ECNR";}
|
||||||
|
|
||||||
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
||||||
virtual ~DL_Algorithm_ECNR() {}
|
virtual ~DL_Algorithm_ECNR() {}
|
||||||
|
|
|
||||||
|
|
@ -138,7 +138,7 @@ struct ElGamal
|
||||||
{
|
{
|
||||||
typedef DL_CryptoSchemeOptions<ElGamal, ElGamalKeys, int, int, int> SchemeOptions;
|
typedef DL_CryptoSchemeOptions<ElGamal, ElGamalKeys, int, int, int> SchemeOptions;
|
||||||
|
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "ElgamalEnc/Crypto++Padding";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "ElgamalEnc/Crypto++Padding";}
|
||||||
|
|
||||||
typedef SchemeOptions::GroupParameters GroupParameters;
|
typedef SchemeOptions::GroupParameters GroupParameters;
|
||||||
//! implements PK_Encryptor interface
|
//! implements PK_Encryptor interface
|
||||||
|
|
|
||||||
2
emsa2.h
2
emsa2.h
|
|
@ -61,7 +61,7 @@ CRYPTOPP_DLL_TEMPLATE_CLASS EMSA2HashId<SHA512>;
|
||||||
class CRYPTOPP_DLL EMSA2Pad : public EMSA2HashIdLookup<PK_DeterministicSignatureMessageEncodingMethod>
|
class CRYPTOPP_DLL EMSA2Pad : public EMSA2HashIdLookup<PK_DeterministicSignatureMessageEncodingMethod>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "EMSA2";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "EMSA2";}
|
||||||
|
|
||||||
size_t MinRepresentativeBitLength(size_t hashIdentifierLength, size_t digestLength) const
|
size_t MinRepresentativeBitLength(size_t hashIdentifierLength, size_t digestLength) const
|
||||||
{CRYPTOPP_UNUSED(hashIdentifierLength); return 8*digestLength + 31;}
|
{CRYPTOPP_UNUSED(hashIdentifierLength); return 8*digestLength + 31;}
|
||||||
|
|
|
||||||
2
esign.h
2
esign.h
|
|
@ -98,7 +98,7 @@ template <class T>
|
||||||
class EMSA5Pad : public PK_DeterministicSignatureMessageEncodingMethod
|
class EMSA5Pad : public PK_DeterministicSignatureMessageEncodingMethod
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "EMSA5";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "EMSA5";}
|
||||||
|
|
||||||
void ComputeMessageRepresentative(RandomNumberGenerator &rng,
|
void ComputeMessageRepresentative(RandomNumberGenerator &rng,
|
||||||
const byte *recoverableMessage, size_t recoverableMessageLength,
|
const byte *recoverableMessage, size_t recoverableMessageLength,
|
||||||
|
|
|
||||||
2
gf2n.cpp
2
gf2n.cpp
|
|
@ -497,7 +497,7 @@ std::ostream& operator<<(std::ostream& out, const PolynomialMod2 &a)
|
||||||
|
|
||||||
static const char upper[]="0123456789ABCDEF";
|
static const char upper[]="0123456789ABCDEF";
|
||||||
static const char lower[]="0123456789abcdef";
|
static const char lower[]="0123456789abcdef";
|
||||||
const char* vec = (out.flags() & std::ios::uppercase) ? upper : lower;
|
const char* const vec = (out.flags() & std::ios::uppercase) ? upper : lower;
|
||||||
|
|
||||||
for (i=0; i*bits < a.BitCount(); i++)
|
for (i=0; i*bits < a.BitCount(); i++)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -196,7 +196,7 @@ template <class T>
|
||||||
class DL_Algorithm_GDSA : public DL_ElgamalLikeSignatureAlgorithm<T>
|
class DL_Algorithm_GDSA : public DL_ElgamalLikeSignatureAlgorithm<T>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "DSA-1363";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "DSA-1363";}
|
||||||
|
|
||||||
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
||||||
virtual ~DL_Algorithm_GDSA() {}
|
virtual ~DL_Algorithm_GDSA() {}
|
||||||
|
|
@ -234,7 +234,7 @@ template <class T>
|
||||||
class DL_Algorithm_NR : public DL_ElgamalLikeSignatureAlgorithm<T>
|
class DL_Algorithm_NR : public DL_ElgamalLikeSignatureAlgorithm<T>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "NR";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "NR";}
|
||||||
|
|
||||||
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
#ifndef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562
|
||||||
virtual ~DL_Algorithm_NR() {}
|
virtual ~DL_Algorithm_NR() {}
|
||||||
|
|
|
||||||
2
gost.h
2
gost.h
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief GOST block cipher information
|
//! \brief GOST block cipher information
|
||||||
struct GOST_Info : public FixedBlockSize<8>, public FixedKeyLength<32>
|
struct GOST_Info : public FixedBlockSize<8>, public FixedKeyLength<32>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "GOST";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "GOST";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class GOST
|
//! \class GOST
|
||||||
|
|
|
||||||
2
idea.h
2
idea.h
|
|
@ -16,7 +16,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \since Crypto++ 1.0
|
//! \since Crypto++ 1.0
|
||||||
struct IDEA_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public FixedRounds<8>
|
struct IDEA_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public FixedRounds<8>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "IDEA";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "IDEA";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class IDEA
|
//! \class IDEA
|
||||||
|
|
|
||||||
2
keccak.h
2
keccak.h
|
|
@ -50,7 +50,7 @@ public:
|
||||||
Keccak(unsigned int digestSize) : m_digestSize(digestSize) {Restart();}
|
Keccak(unsigned int digestSize) : m_digestSize(digestSize) {Restart();}
|
||||||
unsigned int DigestSize() const {return m_digestSize;}
|
unsigned int DigestSize() const {return m_digestSize;}
|
||||||
std::string AlgorithmName() const {return "Keccak-" + IntToString(m_digestSize*8);}
|
std::string AlgorithmName() const {return "Keccak-" + IntToString(m_digestSize*8);}
|
||||||
CRYPTOPP_CONSTEXPR static const char* StaticAlgorithmName() { return "Keccak"; }
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() { return "Keccak"; }
|
||||||
unsigned int OptimalDataAlignment() const {return GetAlignmentOf<word64>();}
|
unsigned int OptimalDataAlignment() const {return GetAlignmentOf<word64>();}
|
||||||
|
|
||||||
void Update(const byte *input, size_t length);
|
void Update(const byte *input, size_t length);
|
||||||
|
|
|
||||||
2
luc.h
2
luc.h
|
|
@ -232,7 +232,7 @@ protected:
|
||||||
class DL_Algorithm_LUC_HMP : public DL_ElgamalLikeSignatureAlgorithm<Integer>
|
class DL_Algorithm_LUC_HMP : public DL_ElgamalLikeSignatureAlgorithm<Integer>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "LUC-HMP";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "LUC-HMP";}
|
||||||
|
|
||||||
void Sign(const DL_GroupParameters<Integer> ¶ms, const Integer &x, const Integer &k, const Integer &e, Integer &r, Integer &s) const;
|
void Sign(const DL_GroupParameters<Integer> ¶ms, const Integer &x, const Integer &k, const Integer &e, Integer &r, Integer &s) const;
|
||||||
bool Verify(const DL_GroupParameters<Integer> ¶ms, const DL_PublicKey<Integer> &publicKey, const Integer &e, const Integer &r, const Integer &s) const;
|
bool Verify(const DL_GroupParameters<Integer> ¶ms, const DL_PublicKey<Integer> &publicKey, const Integer &e, const Integer &r, const Integer &s) const;
|
||||||
|
|
|
||||||
2
mars.h
2
mars.h
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief MARS block cipher information
|
//! \brief MARS block cipher information
|
||||||
struct MARS_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 56, 8>
|
struct MARS_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 56, 8>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "MARS";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "MARS";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class MARS
|
//! \class MARS
|
||||||
|
|
|
||||||
2
md2.h
2
md2.h
|
|
@ -17,7 +17,7 @@ public:
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
unsigned int DigestSize() const {return DIGESTSIZE;}
|
unsigned int DigestSize() const {return DIGESTSIZE;}
|
||||||
unsigned int BlockSize() const {return BLOCKSIZE;}
|
unsigned int BlockSize() const {return BLOCKSIZE;}
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "MD2";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "MD2";}
|
||||||
|
|
||||||
CRYPTOPP_CONSTANT(DIGESTSIZE = 16)
|
CRYPTOPP_CONSTANT(DIGESTSIZE = 16)
|
||||||
CRYPTOPP_CONSTANT(BLOCKSIZE = 16)
|
CRYPTOPP_CONSTANT(BLOCKSIZE = 16)
|
||||||
|
|
|
||||||
2
md4.h
2
md4.h
|
|
@ -15,7 +15,7 @@ class MD4 : public IteratedHashWithStaticTransform<word32, LittleEndian, 64, 16,
|
||||||
public:
|
public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word32 *digest, const word32 *data);
|
static void Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "MD4";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "MD4";}
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
2
md5.h
2
md5.h
|
|
@ -16,7 +16,7 @@ class MD5 : public IteratedHashWithStaticTransform<word32, LittleEndian, 64, 16,
|
||||||
public:
|
public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word32 *digest, const word32 *data);
|
static void Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "MD5";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "MD5";}
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
12
modes.h
12
modes.h
|
|
@ -112,7 +112,7 @@ class CRYPTOPP_DLL CRYPTOPP_NO_VTABLE CFB_ModePolicy : public ModePolicyCommonTe
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
IV_Requirement IVRequirement() const {return RANDOM_IV;}
|
IV_Requirement IVRequirement() const {return RANDOM_IV;}
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "CFB";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "CFB";}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
unsigned int GetBytesPerIteration() const {return m_feedbackSize;}
|
unsigned int GetBytesPerIteration() const {return m_feedbackSize;}
|
||||||
|
|
@ -143,7 +143,7 @@ class CRYPTOPP_DLL CRYPTOPP_NO_VTABLE OFB_ModePolicy : public ModePolicyCommonTe
|
||||||
public:
|
public:
|
||||||
bool CipherIsRandomAccess() const {return false;}
|
bool CipherIsRandomAccess() const {return false;}
|
||||||
IV_Requirement IVRequirement() const {return UNIQUE_IV;}
|
IV_Requirement IVRequirement() const {return UNIQUE_IV;}
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "OFB";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "OFB";}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
unsigned int GetBytesPerIteration() const {return BlockSize();}
|
unsigned int GetBytesPerIteration() const {return BlockSize();}
|
||||||
|
|
@ -159,7 +159,7 @@ class CRYPTOPP_DLL CRYPTOPP_NO_VTABLE CTR_ModePolicy : public ModePolicyCommonTe
|
||||||
public:
|
public:
|
||||||
bool CipherIsRandomAccess() const {return true;}
|
bool CipherIsRandomAccess() const {return true;}
|
||||||
IV_Requirement IVRequirement() const {return RANDOM_IV;}
|
IV_Requirement IVRequirement() const {return RANDOM_IV;}
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "CTR";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "CTR";}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void IncrementCounterBy256();
|
virtual void IncrementCounterBy256();
|
||||||
|
|
@ -216,7 +216,7 @@ public:
|
||||||
IV_Requirement IVRequirement() const {return NOT_RESYNCHRONIZABLE;}
|
IV_Requirement IVRequirement() const {return NOT_RESYNCHRONIZABLE;}
|
||||||
unsigned int OptimalBlockSize() const {return BlockSize() * m_cipher->OptimalNumberOfParallelBlocks();}
|
unsigned int OptimalBlockSize() const {return BlockSize() * m_cipher->OptimalNumberOfParallelBlocks();}
|
||||||
void ProcessData(byte *outString, const byte *inString, size_t length);
|
void ProcessData(byte *outString, const byte *inString, size_t length);
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "ECB";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "ECB";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class CBC_ModeBase
|
//! \class CBC_ModeBase
|
||||||
|
|
@ -227,7 +227,7 @@ public:
|
||||||
IV_Requirement IVRequirement() const {return UNPREDICTABLE_RANDOM_IV;}
|
IV_Requirement IVRequirement() const {return UNPREDICTABLE_RANDOM_IV;}
|
||||||
bool RequireAlignedInput() const {return false;}
|
bool RequireAlignedInput() const {return false;}
|
||||||
unsigned int MinLastBlockSize() const {return 0;}
|
unsigned int MinLastBlockSize() const {return 0;}
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "CBC";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "CBC";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class CBC_Encryption
|
//! \class CBC_Encryption
|
||||||
|
|
@ -246,7 +246,7 @@ public:
|
||||||
void SetStolenIV(byte *iv) {m_stolenIV = iv;}
|
void SetStolenIV(byte *iv) {m_stolenIV = iv;}
|
||||||
unsigned int MinLastBlockSize() const {return BlockSize()+1;}
|
unsigned int MinLastBlockSize() const {return BlockSize()+1;}
|
||||||
void ProcessLastBlock(byte *outString, const byte *inString, size_t length);
|
void ProcessLastBlock(byte *outString, const byte *inString, size_t length);
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "CBC/CTS";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "CBC/CTS";}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UncheckedSetKey(const byte *key, unsigned int length, const NameValuePairs ¶ms)
|
void UncheckedSetKey(const byte *key, unsigned int length, const NameValuePairs ¶ms)
|
||||||
|
|
|
||||||
4
panama.h
4
panama.h
|
|
@ -44,7 +44,7 @@ public:
|
||||||
PanamaHash() {Panama<B>::Reset();}
|
PanamaHash() {Panama<B>::Reset();}
|
||||||
unsigned int DigestSize() const {return DIGESTSIZE;}
|
unsigned int DigestSize() const {return DIGESTSIZE;}
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return B::ToEnum() == BIG_ENDIAN_ORDER ? "Panama-BE" : "Panama-LE";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return B::ToEnum() == BIG_ENDIAN_ORDER ? "Panama-BE" : "Panama-LE";}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void Init() {Panama<B>::Reset();}
|
void Init() {Panama<B>::Reset();}
|
||||||
|
|
@ -128,7 +128,7 @@ public:
|
||||||
template <class B>
|
template <class B>
|
||||||
struct PanamaCipherInfo : public FixedKeyLength<32, SimpleKeyingInterface::UNIQUE_IV, 32>
|
struct PanamaCipherInfo : public FixedKeyLength<32, SimpleKeyingInterface::UNIQUE_IV, 32>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return B::ToEnum() == BIG_ENDIAN_ORDER ? "Panama-BE" : "Panama-LE";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return B::ToEnum() == BIG_ENDIAN_ORDER ? "Panama-BE" : "Panama-LE";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class PanamaCipherPolicy
|
//! \class PanamaCipherPolicy
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
class PKCS_EncryptionPaddingScheme : public PK_EncryptionMessageEncodingMethod
|
class PKCS_EncryptionPaddingScheme : public PK_EncryptionMessageEncodingMethod
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "EME-PKCS1-v1_5";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "EME-PKCS1-v1_5";}
|
||||||
|
|
||||||
size_t MaxUnpaddedLength(size_t paddedLength) const;
|
size_t MaxUnpaddedLength(size_t paddedLength) const;
|
||||||
void Pad(RandomNumberGenerator &rng, const byte *raw, size_t inputLength, byte *padded, size_t paddedLength, const NameValuePairs ¶meters) const;
|
void Pad(RandomNumberGenerator &rng, const byte *raw, size_t inputLength, byte *padded, size_t paddedLength, const NameValuePairs ¶meters) const;
|
||||||
|
|
@ -67,7 +67,7 @@ CRYPTOPP_DLL_TEMPLATE_CLASS PKCS_DigestDecoration<SHA512>;
|
||||||
class CRYPTOPP_DLL PKCS1v15_SignatureMessageEncodingMethod : public PK_DeterministicSignatureMessageEncodingMethod
|
class CRYPTOPP_DLL PKCS1v15_SignatureMessageEncodingMethod : public PK_DeterministicSignatureMessageEncodingMethod
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "EMSA-PKCS1-v1_5";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "EMSA-PKCS1-v1_5";}
|
||||||
|
|
||||||
size_t MinRepresentativeBitLength(size_t hashIdentifierSize, size_t digestSize) const
|
size_t MinRepresentativeBitLength(size_t hashIdentifierSize, size_t digestSize) const
|
||||||
{return 8 * (digestSize + hashIdentifierSize + 10);}
|
{return 8 * (digestSize + hashIdentifierSize + 10);}
|
||||||
|
|
|
||||||
4
pubkey.h
4
pubkey.h
|
|
@ -719,7 +719,7 @@ CRYPTOPP_DLL void CRYPTOPP_API P1363_MGF1KDF2_Common(HashTransformation &hash, b
|
||||||
class P1363_MGF1 : public MaskGeneratingFunction
|
class P1363_MGF1 : public MaskGeneratingFunction
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "MGF1";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "MGF1";}
|
||||||
void GenerateAndMask(HashTransformation &hash, byte *output, size_t outputLength, const byte *input, size_t inputLength, bool mask = true) const
|
void GenerateAndMask(HashTransformation &hash, byte *output, size_t outputLength, const byte *input, size_t inputLength, bool mask = true) const
|
||||||
{
|
{
|
||||||
P1363_MGF1KDF2_Common(hash, output, outputLength, input, inputLength, NULL, 0, mask, 0);
|
P1363_MGF1KDF2_Common(hash, output, outputLength, input, inputLength, NULL, 0, mask, 0);
|
||||||
|
|
@ -1986,7 +1986,7 @@ public:
|
||||||
virtual ~DL_KeyAgreementAlgorithm_DH() {}
|
virtual ~DL_KeyAgreementAlgorithm_DH() {}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName()
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName()
|
||||||
{return COFACTOR_OPTION::ToEnum() == INCOMPATIBLE_COFACTOR_MULTIPLICTION ? "DHC" : "DH";}
|
{return COFACTOR_OPTION::ToEnum() == INCOMPATIBLE_COFACTOR_MULTIPLICTION ? "DHC" : "DH";}
|
||||||
|
|
||||||
Element AgreeWithEphemeralPrivateKey(const DL_GroupParameters<Element> ¶ms, const DL_FixedBasePrecomputation<Element> &publicPrecomputation, const Integer &privateExponent) const
|
Element AgreeWithEphemeralPrivateKey(const DL_GroupParameters<Element> ¶ms, const DL_FixedBasePrecomputation<Element> &publicPrecomputation, const Integer &privateExponent) const
|
||||||
|
|
|
||||||
2
rc2.h
2
rc2.h
|
|
@ -18,7 +18,7 @@ struct RC2_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 1, 128>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTANT(DEFAULT_EFFECTIVE_KEYLENGTH = 1024)
|
CRYPTOPP_CONSTANT(DEFAULT_EFFECTIVE_KEYLENGTH = 1024)
|
||||||
CRYPTOPP_CONSTANT(MAX_EFFECTIVE_KEYLENGTH = 1024)
|
CRYPTOPP_CONSTANT(MAX_EFFECTIVE_KEYLENGTH = 1024)
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RC2";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RC2";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class RC2
|
//! \class RC2
|
||||||
|
|
|
||||||
2
rc5.h
2
rc5.h
|
|
@ -16,7 +16,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \since Crypto++ 1.0
|
//! \since Crypto++ 1.0
|
||||||
struct RC5_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 0, 255>, public VariableRounds<16>
|
struct RC5_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 0, 255>, public VariableRounds<16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RC5";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RC5";}
|
||||||
typedef word32 RC5_WORD;
|
typedef word32 RC5_WORD;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
2
rc6.h
2
rc6.h
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief RC6 block cipher information
|
//! \brief RC6 block cipher information
|
||||||
struct RC6_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>, public VariableRounds<20>
|
struct RC6_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>, public VariableRounds<20>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RC6";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RC6";}
|
||||||
typedef word32 RC6_WORD;
|
typedef word32 RC6_WORD;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
8
ripemd.h
8
ripemd.h
|
|
@ -19,7 +19,7 @@ class RIPEMD160 : public IteratedHashWithStaticTransform<word32, LittleEndian, 6
|
||||||
public:
|
public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word32 *digest, const word32 *data);
|
static void Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RIPEMD-160";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RIPEMD-160";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class RIPEMD320
|
//! \class RIPEMD320
|
||||||
|
|
@ -31,7 +31,7 @@ class RIPEMD320 : public IteratedHashWithStaticTransform<word32, LittleEndian, 6
|
||||||
public:
|
public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word32 *digest, const word32 *data);
|
static void Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RIPEMD-320";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RIPEMD-320";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class RIPEMD128
|
//! \class RIPEMD128
|
||||||
|
|
@ -44,7 +44,7 @@ class RIPEMD128 : public IteratedHashWithStaticTransform<word32, LittleEndian, 6
|
||||||
public:
|
public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word32 *digest, const word32 *data);
|
static void Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RIPEMD-128";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RIPEMD-128";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class RIPEMD256
|
//! \class RIPEMD256
|
||||||
|
|
@ -57,7 +57,7 @@ class RIPEMD256 : public IteratedHashWithStaticTransform<word32, LittleEndian, 6
|
||||||
public:
|
public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word32 *digest, const word32 *data);
|
static void Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "RIPEMD-256";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "RIPEMD-256";}
|
||||||
};
|
};
|
||||||
|
|
||||||
NAMESPACE_END
|
NAMESPACE_END
|
||||||
|
|
|
||||||
4
rsa.h
4
rsa.h
|
|
@ -157,7 +157,7 @@ public:
|
||||||
//! \since Crypto++ 1.0
|
//! \since Crypto++ 1.0
|
||||||
struct CRYPTOPP_DLL RSA
|
struct CRYPTOPP_DLL RSA
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "RSA";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "RSA";}
|
||||||
typedef RSAFunction PublicKey;
|
typedef RSAFunction PublicKey;
|
||||||
typedef InvertibleRSAFunction PrivateKey;
|
typedef InvertibleRSAFunction PrivateKey;
|
||||||
};
|
};
|
||||||
|
|
@ -189,7 +189,7 @@ struct RSASS : public TF_SS<STANDARD, H, RSA>
|
||||||
//! \since Crypto++ 1.0
|
//! \since Crypto++ 1.0
|
||||||
struct CRYPTOPP_DLL RSA_ISO
|
struct CRYPTOPP_DLL RSA_ISO
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "RSA-ISO";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "RSA-ISO";}
|
||||||
typedef RSAFunction_ISO PublicKey;
|
typedef RSAFunction_ISO PublicKey;
|
||||||
typedef InvertibleRSAFunction_ISO PrivateKey;
|
typedef InvertibleRSAFunction_ISO PrivateKey;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
4
safer.h
4
safer.h
|
|
@ -66,7 +66,7 @@ protected:
|
||||||
//! \brief SAFER-K block cipher information
|
//! \brief SAFER-K block cipher information
|
||||||
struct SAFER_K_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 8, 16, 8>, public VariableRounds<10, 1, 13>
|
struct SAFER_K_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 8, 16, 8>, public VariableRounds<10, 1, 13>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "SAFER-K";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "SAFER-K";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SAFER_K
|
//! \class SAFER_K
|
||||||
|
|
@ -83,7 +83,7 @@ public:
|
||||||
//! \brief SAFER-SK block cipher information
|
//! \brief SAFER-SK block cipher information
|
||||||
struct SAFER_SK_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 8, 16, 8>, public VariableRounds<10, 1, 13>
|
struct SAFER_SK_Info : public FixedBlockSize<8>, public VariableKeyLength<16, 8, 16, 8>, public VariableRounds<10, 1, 13>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "SAFER-SK";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "SAFER-SK";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SAFER_SK
|
//! \class SAFER_SK
|
||||||
|
|
|
||||||
4
salsa.h
4
salsa.h
|
|
@ -22,7 +22,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief Salsa20 stream cipher information
|
//! \brief Salsa20 stream cipher information
|
||||||
struct Salsa20_Info : public VariableKeyLength<32, 16, 32, 16, SimpleKeyingInterface::UNIQUE_IV, 8>
|
struct Salsa20_Info : public VariableKeyLength<32, 16, 32, 16, SimpleKeyingInterface::UNIQUE_IV, 8>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Salsa20";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Salsa20";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class Salsa20_Policy
|
//! \class Salsa20_Policy
|
||||||
|
|
@ -58,7 +58,7 @@ struct Salsa20 : public Salsa20_Info, public SymmetricCipherDocumentation
|
||||||
//! \brief XSalsa20 stream cipher information
|
//! \brief XSalsa20 stream cipher information
|
||||||
struct XSalsa20_Info : public FixedKeyLength<32, SimpleKeyingInterface::UNIQUE_IV, 24>
|
struct XSalsa20_Info : public FixedKeyLength<32, SimpleKeyingInterface::UNIQUE_IV, 24>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "XSalsa20";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "XSalsa20";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class XSalsa20_Policy
|
//! \class XSalsa20_Policy
|
||||||
|
|
|
||||||
2
seal.h
2
seal.h
|
|
@ -17,7 +17,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
template <class B = BigEndian>
|
template <class B = BigEndian>
|
||||||
struct SEAL_Info : public FixedKeyLength<20, SimpleKeyingInterface::INTERNALLY_GENERATED_IV, 4>
|
struct SEAL_Info : public FixedKeyLength<20, SimpleKeyingInterface::INTERNALLY_GENERATED_IV, 4>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return B::ToEnum() == LITTLE_ENDIAN_ORDER ? "SEAL-3.0-LE" : "SEAL-3.0-BE";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return B::ToEnum() == LITTLE_ENDIAN_ORDER ? "SEAL-3.0-LE" : "SEAL-3.0-BE";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SEAL_Policy
|
//! \class SEAL_Policy
|
||||||
|
|
|
||||||
6
seckey.h
6
seckey.h
|
|
@ -70,7 +70,7 @@ public:
|
||||||
//! provided by a static function.
|
//! provided by a static function.
|
||||||
//! \param keylength the size of the key, in bytes
|
//! \param keylength the size of the key, in bytes
|
||||||
//! \details keylength is unused in the default implementation.
|
//! \details keylength is unused in the default implementation.
|
||||||
CRYPTOPP_CONSTEXPR static unsigned int StaticGetDefaultRounds(size_t keylength)
|
CRYPTOPP_STATIC_CONSTEXPR unsigned int StaticGetDefaultRounds(size_t keylength)
|
||||||
{
|
{
|
||||||
// Comma operator breaks Debug builds with GCC 4.0 - 4.6.
|
// Comma operator breaks Debug builds with GCC 4.0 - 4.6.
|
||||||
// Also see http://github.com/weidai11/cryptopp/issues/255
|
// Also see http://github.com/weidai11/cryptopp/issues/255
|
||||||
|
|
@ -151,7 +151,7 @@ public:
|
||||||
//! \param keylength the size of the key, in bytes
|
//! \param keylength the size of the key, in bytes
|
||||||
//! \details The default implementation returns KEYLENGTH. keylength is unused
|
//! \details The default implementation returns KEYLENGTH. keylength is unused
|
||||||
//! in the default implementation.
|
//! in the default implementation.
|
||||||
CRYPTOPP_CONSTEXPR static size_t CRYPTOPP_API StaticGetValidKeyLength(size_t keylength)
|
CRYPTOPP_STATIC_CONSTEXPR size_t CRYPTOPP_API StaticGetValidKeyLength(size_t keylength)
|
||||||
{
|
{
|
||||||
// Comma operator breaks Debug builds with GCC 4.0 - 4.6.
|
// Comma operator breaks Debug builds with GCC 4.0 - 4.6.
|
||||||
// Also see http://github.com/weidai11/cryptopp/issues/255
|
// Also see http://github.com/weidai11/cryptopp/issues/255
|
||||||
|
|
@ -261,7 +261,7 @@ public:
|
||||||
//! then keylength is returned. Otherwise, the function returns keylength rounded
|
//! then keylength is returned. Otherwise, the function returns keylength rounded
|
||||||
//! \a down to the next smaller multiple of KEYLENGTH_MULTIPLE.
|
//! \a down to the next smaller multiple of KEYLENGTH_MULTIPLE.
|
||||||
//! \details keylength is provided in bytes, not bits.
|
//! \details keylength is provided in bytes, not bits.
|
||||||
CRYPTOPP_CONSTEXPR static size_t CRYPTOPP_API StaticGetValidKeyLength(size_t keylength)
|
CRYPTOPP_STATIC_CONSTEXPR size_t CRYPTOPP_API StaticGetValidKeyLength(size_t keylength)
|
||||||
{return T::StaticGetValidKeyLength(keylength);}
|
{return T::StaticGetValidKeyLength(keylength);}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
2
seed.h
2
seed.h
|
|
@ -17,7 +17,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \since Crypto++ 5.6.0
|
//! \since Crypto++ 5.6.0
|
||||||
struct SEED_Info : public FixedBlockSize<16>, public FixedKeyLength<16>, public FixedRounds<16>
|
struct SEED_Info : public FixedBlockSize<16>, public FixedKeyLength<16>, public FixedRounds<16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "SEED";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "SEED";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SEED
|
//! \class SEED
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief Serpent block cipher information
|
//! \brief Serpent block cipher information
|
||||||
struct Serpent_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>, public FixedRounds<32>
|
struct Serpent_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>, public FixedRounds<32>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Serpent";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Serpent";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class Serpent
|
//! \class Serpent
|
||||||
|
|
|
||||||
10
sha.h
10
sha.h
|
|
@ -27,7 +27,7 @@ class CRYPTOPP_DLL SHA1 : public IteratedHashWithStaticTransform<word32, BigEndi
|
||||||
public:
|
public:
|
||||||
static void CRYPTOPP_API InitState(HashWordType *state);
|
static void CRYPTOPP_API InitState(HashWordType *state);
|
||||||
static void CRYPTOPP_API Transform(word32 *digest, const word32 *data);
|
static void CRYPTOPP_API Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "SHA-1";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "SHA-1";}
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef SHA1 SHA; // for backwards compatibility
|
typedef SHA1 SHA; // for backwards compatibility
|
||||||
|
|
@ -44,7 +44,7 @@ public:
|
||||||
#endif
|
#endif
|
||||||
static void CRYPTOPP_API InitState(HashWordType *state);
|
static void CRYPTOPP_API InitState(HashWordType *state);
|
||||||
static void CRYPTOPP_API Transform(word32 *digest, const word32 *data);
|
static void CRYPTOPP_API Transform(word32 *digest, const word32 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "SHA-256";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "SHA-256";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SHA224
|
//! \class SHA224
|
||||||
|
|
@ -59,7 +59,7 @@ public:
|
||||||
#endif
|
#endif
|
||||||
static void CRYPTOPP_API InitState(HashWordType *state);
|
static void CRYPTOPP_API InitState(HashWordType *state);
|
||||||
static void CRYPTOPP_API Transform(word32 *digest, const word32 *data) {SHA256::Transform(digest, data);}
|
static void CRYPTOPP_API Transform(word32 *digest, const word32 *data) {SHA256::Transform(digest, data);}
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "SHA-224";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "SHA-224";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SHA512
|
//! \class SHA512
|
||||||
|
|
@ -71,7 +71,7 @@ class CRYPTOPP_DLL SHA512 : public IteratedHashWithStaticTransform<word64, BigEn
|
||||||
public:
|
public:
|
||||||
static void CRYPTOPP_API InitState(HashWordType *state);
|
static void CRYPTOPP_API InitState(HashWordType *state);
|
||||||
static void CRYPTOPP_API Transform(word64 *digest, const word64 *data);
|
static void CRYPTOPP_API Transform(word64 *digest, const word64 *data);
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "SHA-512";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "SHA-512";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SHA384
|
//! \class SHA384
|
||||||
|
|
@ -83,7 +83,7 @@ class CRYPTOPP_DLL SHA384 : public IteratedHashWithStaticTransform<word64, BigEn
|
||||||
public:
|
public:
|
||||||
static void CRYPTOPP_API InitState(HashWordType *state);
|
static void CRYPTOPP_API InitState(HashWordType *state);
|
||||||
static void CRYPTOPP_API Transform(word64 *digest, const word64 *data) {SHA512::Transform(digest, data);}
|
static void CRYPTOPP_API Transform(word64 *digest, const word64 *data) {SHA512::Transform(digest, data);}
|
||||||
CRYPTOPP_CONSTEXPR static const char * CRYPTOPP_API StaticAlgorithmName() {return "SHA-384";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const CRYPTOPP_API StaticAlgorithmName() {return "SHA-384";}
|
||||||
};
|
};
|
||||||
|
|
||||||
NAMESPACE_END
|
NAMESPACE_END
|
||||||
|
|
|
||||||
2
sha3.h
2
sha3.h
|
|
@ -36,7 +36,7 @@ public:
|
||||||
SHA3(unsigned int digestSize) : m_digestSize(digestSize) {Restart();}
|
SHA3(unsigned int digestSize) : m_digestSize(digestSize) {Restart();}
|
||||||
unsigned int DigestSize() const {return m_digestSize;}
|
unsigned int DigestSize() const {return m_digestSize;}
|
||||||
std::string AlgorithmName() const {return "SHA3-" + IntToString(m_digestSize*8);}
|
std::string AlgorithmName() const {return "SHA3-" + IntToString(m_digestSize*8);}
|
||||||
CRYPTOPP_CONSTEXPR static const char* StaticAlgorithmName() { return "SHA3"; }
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() { return "SHA3"; }
|
||||||
unsigned int OptimalDataAlignment() const {return GetAlignmentOf<word64>();}
|
unsigned int OptimalDataAlignment() const {return GetAlignmentOf<word64>();}
|
||||||
|
|
||||||
void Update(const byte *input, size_t length);
|
void Update(const byte *input, size_t length);
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief SHACAL2 block cipher information
|
//! \brief SHACAL2 block cipher information
|
||||||
struct SHACAL2_Info : public FixedBlockSize<32>, public VariableKeyLength<16, 16, 64>
|
struct SHACAL2_Info : public FixedBlockSize<32>, public VariableKeyLength<16, 16, 64>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "SHACAL-2";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "SHACAL-2";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SHACAL2
|
//! \class SHACAL2
|
||||||
|
|
|
||||||
2
shark.h
2
shark.h
|
|
@ -16,7 +16,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief SHARK block cipher information
|
//! \brief SHARK block cipher information
|
||||||
struct SHARK_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public VariableRounds<6, 2>
|
struct SHARK_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public VariableRounds<6, 2>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "SHARK-E";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "SHARK-E";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SHARK
|
//! \class SHARK
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \since Crypto++ 5.5
|
//! \since Crypto++ 5.5
|
||||||
struct SosemanukInfo : public VariableKeyLength<16, 1, 32, 1, SimpleKeyingInterface::UNIQUE_IV, 16>
|
struct SosemanukInfo : public VariableKeyLength<16, 1, 32, 1, SimpleKeyingInterface::UNIQUE_IV, 16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Sosemanuk";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Sosemanuk";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class SosemanukPolicy
|
//! \class SosemanukPolicy
|
||||||
|
|
|
||||||
2
square.h
2
square.h
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief Square block cipher information
|
//! \brief Square block cipher information
|
||||||
struct Square_Info : public FixedBlockSize<16>, public FixedKeyLength<16>, FixedRounds<8>
|
struct Square_Info : public FixedBlockSize<16>, public FixedKeyLength<16>, FixedRounds<8>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Square";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Square";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class Square
|
//! \class Square
|
||||||
|
|
|
||||||
6
tea.h
6
tea.h
|
|
@ -16,7 +16,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief TEA block cipher information
|
//! \brief TEA block cipher information
|
||||||
struct TEA_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public VariableRounds<32>
|
struct TEA_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public VariableRounds<32>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "TEA";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "TEA";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class TEA
|
//! \class TEA
|
||||||
|
|
@ -64,7 +64,7 @@ typedef TEA::Decryption TEADecryption;
|
||||||
//! \brief XTEA block cipher information
|
//! \brief XTEA block cipher information
|
||||||
struct XTEA_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public VariableRounds<32>
|
struct XTEA_Info : public FixedBlockSize<8>, public FixedKeyLength<16>, public VariableRounds<32>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "XTEA";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "XTEA";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class XTEA
|
//! \class XTEA
|
||||||
|
|
@ -109,7 +109,7 @@ public:
|
||||||
//! \brief BTEA block cipher information
|
//! \brief BTEA block cipher information
|
||||||
struct BTEA_Info : public FixedKeyLength<16>
|
struct BTEA_Info : public FixedKeyLength<16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "BTEA";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "BTEA";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class BTEA
|
//! \class BTEA
|
||||||
|
|
|
||||||
2
tiger.h
2
tiger.h
|
|
@ -19,7 +19,7 @@ public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word64 *digest, const word64 *data);
|
static void Transform(word64 *digest, const word64 *data);
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Tiger";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Tiger";}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
static const word64 table[4*256+3];
|
static const word64 table[4*256+3];
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
//! \brief Twofish block cipher information
|
//! \brief Twofish block cipher information
|
||||||
struct Twofish_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>, FixedRounds<16>
|
struct Twofish_Info : public FixedBlockSize<16>, public VariableKeyLength<16, 16, 32, 8>, FixedRounds<16>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Twofish";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Twofish";}
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class Twofish
|
//! \class Twofish
|
||||||
|
|
|
||||||
2
wake.h
2
wake.h
|
|
@ -19,7 +19,7 @@ NAMESPACE_BEGIN(CryptoPP)
|
||||||
template <class B = BigEndian>
|
template <class B = BigEndian>
|
||||||
struct WAKE_OFB_Info : public FixedKeyLength<32>
|
struct WAKE_OFB_Info : public FixedKeyLength<32>
|
||||||
{
|
{
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return B::ToEnum() == LITTLE_ENDIAN_ORDER ? "WAKE-OFB-LE" : "WAKE-OFB-BE";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return B::ToEnum() == LITTLE_ENDIAN_ORDER ? "WAKE-OFB-LE" : "WAKE-OFB-BE";}
|
||||||
};
|
};
|
||||||
|
|
||||||
class CRYPTOPP_NO_VTABLE WAKE_Base
|
class CRYPTOPP_NO_VTABLE WAKE_Base
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ public:
|
||||||
static void InitState(HashWordType *state);
|
static void InitState(HashWordType *state);
|
||||||
static void Transform(word64 *digest, const word64 *data);
|
static void Transform(word64 *digest, const word64 *data);
|
||||||
void TruncatedFinal(byte *hash, size_t size);
|
void TruncatedFinal(byte *hash, size_t size);
|
||||||
CRYPTOPP_CONSTEXPR static const char *StaticAlgorithmName() {return "Whirlpool";}
|
CRYPTOPP_STATIC_CONSTEXPR char* const StaticAlgorithmName() {return "Whirlpool";}
|
||||||
};
|
};
|
||||||
|
|
||||||
NAMESPACE_END
|
NAMESPACE_END
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue