Commented typedef guarded by CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
The typedefs were only commented so folks could search for a missing symbol, like Crypto++ 4.0 PK_FixedLengthEncryptor or PK_FixedLengthDecryptor This is a distinct change from CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY_562pull/347/head
parent
f06c968b62
commit
bded4d385f
72
cryptlib.h
72
cryptlib.h
|
|
@ -260,9 +260,9 @@ struct CRYPTOPP_DLL DecodingResult
|
||||||
//! \brief Recovered message length if isValidCoding is true, undefined otherwise
|
//! \brief Recovered message length if isValidCoding is true, undefined otherwise
|
||||||
size_t messageLength;
|
size_t messageLength;
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
operator size_t() const {return isValidCoding ? messageLength : 0;}
|
//operator size_t() const {return isValidCoding ? messageLength : 0;}
|
||||||
#endif
|
//#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class NameValuePairs
|
//! \class NameValuePairs
|
||||||
|
|
@ -1177,9 +1177,9 @@ protected:
|
||||||
{CRYPTOPP_UNUSED(headerLength); CRYPTOPP_UNUSED(messageLength); CRYPTOPP_UNUSED(footerLength);}
|
{CRYPTOPP_UNUSED(headerLength); CRYPTOPP_UNUSED(messageLength); CRYPTOPP_UNUSED(footerLength);}
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
typedef SymmetricCipher StreamCipher;
|
//typedef SymmetricCipher StreamCipher;
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
//! \class RandomNumberGenerator
|
//! \class RandomNumberGenerator
|
||||||
//! \brief Interface for random number generators
|
//! \brief Interface for random number generators
|
||||||
|
|
@ -1268,13 +1268,13 @@ public:
|
||||||
std::iter_swap(begin, begin + GenerateWord32(0, end-begin-1));
|
std::iter_swap(begin, begin + GenerateWord32(0, end-begin-1));
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
byte GetByte() {return GenerateByte();}
|
//byte GetByte() {return GenerateByte();}
|
||||||
unsigned int GetBit() {return GenerateBit();}
|
//unsigned int GetBit() {return GenerateBit();}
|
||||||
word32 GetLong(word32 a=0, word32 b=0xffffffffL) {return GenerateWord32(a, b);}
|
//word32 GetLong(word32 a=0, word32 b=0xffffffffL) {return GenerateWord32(a, b);}
|
||||||
word16 GetShort(word16 a=0, word16 b=0xffff) {return (word16)GenerateWord32(a, b);}
|
//word16 GetShort(word16 a=0, word16 b=0xffff) {return (word16)GenerateWord32(a, b);}
|
||||||
void GetBlock(byte *output, size_t size) {GenerateBlock(output, size);}
|
//void GetBlock(byte *output, size_t size) {GenerateBlock(output, size);}
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -1566,9 +1566,9 @@ public:
|
||||||
virtual int GetAutoSignalPropagation() const {return 0;}
|
virtual int GetAutoSignalPropagation() const {return 0;}
|
||||||
public:
|
public:
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
void Close() {MessageEnd();}
|
//void Close() {MessageEnd();}
|
||||||
#endif
|
//#endif
|
||||||
//@}
|
//@}
|
||||||
|
|
||||||
//! \name RETRIEVAL OF ONE MESSAGE
|
//! \name RETRIEVAL OF ONE MESSAGE
|
||||||
|
|
@ -1692,9 +1692,9 @@ public:
|
||||||
lword CopyRangeTo(BufferedTransformation &target, lword position, lword copyMax=LWORD_MAX, const std::string &channel=DEFAULT_CHANNEL) const
|
lword CopyRangeTo(BufferedTransformation &target, lword position, lword copyMax=LWORD_MAX, const std::string &channel=DEFAULT_CHANNEL) const
|
||||||
{lword i = position; CopyRangeTo2(target, i, i+copyMax, channel); return i-position;}
|
{lword i = position; CopyRangeTo2(target, i, i+copyMax, channel); return i-position;}
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
unsigned long MaxRetrieveable() const {return MaxRetrievable();}
|
//unsigned long MaxRetrieveable() const {return MaxRetrievable();}
|
||||||
#endif
|
//#endif
|
||||||
//@}
|
//@}
|
||||||
|
|
||||||
//! \name RETRIEVAL OF MULTIPLE MESSAGES
|
//! \name RETRIEVAL OF MULTIPLE MESSAGES
|
||||||
|
|
@ -2325,10 +2325,10 @@ public:
|
||||||
//! length, if one exists, otherwise return 0.
|
//! length, if one exists, otherwise return 0.
|
||||||
virtual size_t FixedMaxPlaintextLength() const {return 0;}
|
virtual size_t FixedMaxPlaintextLength() const {return 0;}
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
//size_t MaxPlainTextLength(size_t cipherTextLength) const {return MaxPlaintextLength(cipherTextLength);}
|
//size_t MaxPlainTextLength(size_t cipherTextLength) const {return MaxPlaintextLength(cipherTextLength);}
|
||||||
//size_t CipherTextLength(size_t plainTextLength) const {return CiphertextLength(plainTextLength);}
|
//size_t CipherTextLength(size_t plainTextLength) const {return CiphertextLength(plainTextLength);}
|
||||||
#endif
|
//#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \class PK_Encryptor
|
//! \class PK_Encryptor
|
||||||
|
|
@ -2418,11 +2418,11 @@ public:
|
||||||
{return Decrypt(rng, ciphertext, FixedCiphertextLength(), plaintext, parameters);}
|
{return Decrypt(rng, ciphertext, FixedCiphertextLength(), plaintext, parameters);}
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
//typedef PK_CryptoSystem PK_FixedLengthCryptoSystem;
|
//typedef PK_CryptoSystem PK_FixedLengthCryptoSystem;
|
||||||
//typedef PK_Encryptor PK_FixedLengthEncryptor;
|
//typedef PK_Encryptor PK_FixedLengthEncryptor;
|
||||||
//typedef PK_Decryptor PK_FixedLengthDecryptor;
|
//typedef PK_Decryptor PK_FixedLengthDecryptor;
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
//! \class PK_SignatureScheme
|
//! \class PK_SignatureScheme
|
||||||
//! \brief Interface for public-key signers and verifiers
|
//! \brief Interface for public-key signers and verifiers
|
||||||
|
|
@ -2713,10 +2713,10 @@ public:
|
||||||
//! \pre <tt>COUNTOF(otherPublicKey) == PublicKeyLength()</tt>
|
//! \pre <tt>COUNTOF(otherPublicKey) == PublicKeyLength()</tt>
|
||||||
virtual bool Agree(byte *agreedValue, const byte *privateKey, const byte *otherPublicKey, bool validateOtherPublicKey=true) const =0;
|
virtual bool Agree(byte *agreedValue, const byte *privateKey, const byte *otherPublicKey, bool validateOtherPublicKey=true) const =0;
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
bool ValidateDomainParameters(RandomNumberGenerator &rng) const
|
//bool ValidateDomainParameters(RandomNumberGenerator &rng) const
|
||||||
{return GetCryptoParameters().Validate(rng, 2);}
|
// {return GetCryptoParameters().Validate(rng, 2);}
|
||||||
#endif
|
//#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
//! \brief Interface for domains of authenticated key agreement protocols
|
//! \brief Interface for domains of authenticated key agreement protocols
|
||||||
|
|
@ -2811,10 +2811,10 @@ public:
|
||||||
const byte *staticOtherPublicKey, const byte *ephemeralOtherPublicKey,
|
const byte *staticOtherPublicKey, const byte *ephemeralOtherPublicKey,
|
||||||
bool validateStaticOtherPublicKey=true) const =0;
|
bool validateStaticOtherPublicKey=true) const =0;
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
bool ValidateDomainParameters(RandomNumberGenerator &rng) const
|
// bool ValidateDomainParameters(RandomNumberGenerator &rng) const
|
||||||
{return GetCryptoParameters().Validate(rng, 2);}
|
// {return GetCryptoParameters().Validate(rng, 2);}
|
||||||
#endif
|
//#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
// interface for password authenticated key agreement protocols, not implemented yet
|
// interface for password authenticated key agreement protocols, not implemented yet
|
||||||
|
|
@ -2960,11 +2960,11 @@ public:
|
||||||
virtual void BEREncode(BufferedTransformation &bt) const {DEREncode(bt);}
|
virtual void BEREncode(BufferedTransformation &bt) const {DEREncode(bt);}
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
typedef PK_SignatureScheme PK_SignatureSystem;
|
//typedef PK_SignatureScheme PK_SignatureSystem;
|
||||||
typedef SimpleKeyAgreementDomain PK_SimpleKeyAgreementDomain;
|
//typedef SimpleKeyAgreementDomain PK_SimpleKeyAgreementDomain;
|
||||||
typedef AuthenticatedKeyAgreementDomain PK_AuthenticatedKeyAgreementDomain;
|
//typedef AuthenticatedKeyAgreementDomain PK_AuthenticatedKeyAgreementDomain;
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
NAMESPACE_END
|
NAMESPACE_END
|
||||||
|
|
||||||
|
|
|
||||||
10
eccrypto.h
10
eccrypto.h
|
|
@ -129,11 +129,11 @@ public:
|
||||||
bool operator==(const ThisClass &rhs) const
|
bool operator==(const ThisClass &rhs) const
|
||||||
{return this->m_groupPrecomputation.GetCurve() == rhs.m_groupPrecomputation.GetCurve() && this->m_gpc.GetBase(this->m_groupPrecomputation) == rhs.m_gpc.GetBase(rhs.m_groupPrecomputation);}
|
{return this->m_groupPrecomputation.GetCurve() == rhs.m_groupPrecomputation.GetCurve() && this->m_gpc.GetBase(this->m_groupPrecomputation) == rhs.m_gpc.GetBase(rhs.m_groupPrecomputation);}
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
const Point& GetBasePoint() const {return this->GetSubgroupGenerator();}
|
//const Point& GetBasePoint() const {return this->GetSubgroupGenerator();}
|
||||||
const Integer& GetBasePointOrder() const {return this->GetSubgroupOrder();}
|
//const Integer& GetBasePointOrder() const {return this->GetSubgroupOrder();}
|
||||||
void LoadRecommendedParameters(const OID &oid) {Initialize(oid);}
|
//void LoadRecommendedParameters(const OID &oid) {Initialize(oid);}
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
unsigned int FieldElementLength() const {return GetCurve().GetField().MaxElementByteLength();}
|
unsigned int FieldElementLength() const {return GetCurve().GetField().MaxElementByteLength();}
|
||||||
|
|
|
||||||
4
modes.h
4
modes.h
|
|
@ -462,12 +462,12 @@ struct CBC_CTS_Mode_ExternalCipher : public CipherModeDocumentation
|
||||||
typedef CipherModeFinalTemplate_ExternalCipher<CBC_CTS_Decryption> Decryption;
|
typedef CipherModeFinalTemplate_ExternalCipher<CBC_CTS_Decryption> Decryption;
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
//#ifdef CRYPTOPP_MAINTAIN_BACKWARDS_COMPATIBILITY
|
||||||
//typedef CFB_Mode_ExternalCipher::Encryption CFBEncryption;
|
//typedef CFB_Mode_ExternalCipher::Encryption CFBEncryption;
|
||||||
//typedef CFB_Mode_ExternalCipher::Decryption CFBDecryption;
|
//typedef CFB_Mode_ExternalCipher::Decryption CFBDecryption;
|
||||||
//typedef OFB_Mode_ExternalCipher::Encryption OFB;
|
//typedef OFB_Mode_ExternalCipher::Encryption OFB;
|
||||||
//typedef CTR_Mode_ExternalCipher::Encryption CounterMode;
|
//typedef CTR_Mode_ExternalCipher::Encryption CounterMode;
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
NAMESPACE_END
|
NAMESPACE_END
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue