don't do namespace hack

This commit is contained in:
Glenn Maynard
2006-02-03 19:58:38 +00:00
parent 61f5eeb5e5
commit 0cb1e5e337
43 changed files with 89 additions and 89 deletions
+2 -2
View File
@@ -6,7 +6,7 @@
#include <vector> #include <vector>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
template <class T> const T& AbstractGroup<T>::Double(const Element &a) const template <class T> const T& AbstractGroup<T>::Double(const Element &a) const
{ {
@@ -337,4 +337,4 @@ void AbstractRing<T>::SimultaneousExponentiate(T *results, const T &base, const
MultiplicativeGroup().AbstractGroup<T>::SimultaneousMultiply(results, base, exponents, expCount); MultiplicativeGroup().AbstractGroup<T>::SimultaneousMultiply(results, base, exponents, expCount);
} }
NAMESPACE_END }
+2 -2
View File
@@ -3,7 +3,7 @@
#include "config.h" #include "config.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
class Integer; class Integer;
@@ -270,6 +270,6 @@ protected:
Element m_modulus; Element m_modulus;
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -3,8 +3,8 @@
#include "pch.h" #include "pch.h"
#include "algparam.h" #include "algparam.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
bool (*AssignIntToInteger)(const std::type_info &valueType, void *pInteger, const void *pInt) = NULL; bool (*AssignIntToInteger)(const std::type_info &valueType, void *pInteger, const void *pInt) = NULL;
NAMESPACE_END }
+2 -2
View File
@@ -5,7 +5,7 @@
#include "smartptr.h" #include "smartptr.h"
#include "secblock.h" #include "secblock.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! used to pass byte array input as part of a NameValuePairs object //! used to pass byte array input as part of a NameValuePairs object
/*! the deepCopy option is used when the NameValuePairs object can't /*! the deepCopy option is used when the NameValuePairs object can't
@@ -320,6 +320,6 @@ AlgorithmParameters<NullNameValuePairs,T> MakeParameters(const char *name, const
#define CRYPTOPP_SET_FUNCTION_ENTRY(name) (Name::name(), &ThisClass::Set##name) #define CRYPTOPP_SET_FUNCTION_ENTRY(name) (Name::name(), &ThisClass::Set##name)
#define CRYPTOPP_SET_FUNCTION_ENTRY2(name1, name2) (Name::name1(), Name::name2(), &ThisClass::Set##name1##And##name2) #define CRYPTOPP_SET_FUNCTION_ENTRY2(name1, name2) (Name::name1(), Name::name2(), &ThisClass::Set##name1##And##name2)
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -3,7 +3,7 @@
#include "cryptlib.h" #include "cryptlib.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
DOCUMENTED_NAMESPACE_BEGIN(Name) DOCUMENTED_NAMESPACE_BEGIN(Name)
@@ -49,6 +49,6 @@ CRYPTOPP_DEFINE_NAME_STRING(XMACC_Counter) //!< word32
DOCUMENTED_NAMESPACE_END DOCUMENTED_NAMESPACE_END
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -6,7 +6,7 @@
#include <iomanip> #include <iomanip>
#include <time.h> #include <time.h>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
USING_NAMESPACE(std) USING_NAMESPACE(std)
/// DER Length /// DER Length
@@ -553,4 +553,4 @@ void PKCS8PrivateKey::DEREncode(BufferedTransformation &bt) const
privateKeyInfo.MessageEnd(); privateKeyInfo.MessageEnd();
} }
NAMESPACE_END }
+1 -1
View File
@@ -5,7 +5,7 @@
#include "queue.h" #include "queue.h"
#include <vector> #include <vector>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
// these tags and flags are not complete // these tags and flags are not complete
enum ASNTag enum ASNTag
+2 -2
View File
@@ -107,7 +107,7 @@
typedef unsigned char byte; // moved outside namespace for Borland C++Builder 5 typedef unsigned char byte; // moved outside namespace for Borland C++Builder 5
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
typedef unsigned short word16; typedef unsigned short word16;
#if defined(__alpha) && !defined(_MSC_VER) #if defined(__alpha) && !defined(_MSC_VER)
@@ -178,7 +178,7 @@ union dword_union
# define FAST_ROTATE # define FAST_ROTATE
#endif #endif
NAMESPACE_END }
// VC60 workaround: it doesn't allow typename in some places // VC60 workaround: it doesn't allow typename in some places
#if defined(_MSC_VER) && (_MSC_VER < 1300) #if defined(_MSC_VER) && (_MSC_VER < 1300)
+2 -2
View File
@@ -9,7 +9,7 @@
#include <memory> #include <memory>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//CRYPTOPP_COMPILE_ASSERT(sizeof(byte) == 1); //CRYPTOPP_COMPILE_ASSERT(sizeof(byte) == 1);
//CRYPTOPP_COMPILE_ASSERT(sizeof(word32) == 4); //CRYPTOPP_COMPILE_ASSERT(sizeof(word32) == 4);
@@ -648,4 +648,4 @@ DecodingResult PK_Verifier::RecoverMessage(byte *recoveredMessage,
return RecoverAndRestart(recoveredMessage, *m); return RecoverAndRestart(recoveredMessage, *m);
} }
NAMESPACE_END }
+1 -1
View File
@@ -62,7 +62,7 @@ and getting me started with this manual.
#include <typeinfo> #include <typeinfo>
#include <assert.h> #include <assert.h>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
// forward declarations // forward declarations
class Integer; class Integer;
+2 -2
View File
@@ -3,7 +3,7 @@
#include "pch.h" #include "pch.h"
#include "files.h" #include "files.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
using namespace std; using namespace std;
@@ -184,4 +184,4 @@ unsigned int FileSink::Put2(const byte *inString, unsigned int length, int messa
return 0; return 0;
} }
NAMESPACE_END }
+2 -2
View File
@@ -7,7 +7,7 @@
#include <iostream> #include <iostream>
#include <fstream> #include <fstream>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! . //! .
class FileStore : public Store, private FilterPutSpaceHelper class FileStore : public Store, private FilterPutSpaceHelper
@@ -90,6 +90,6 @@ private:
std::ostream *m_stream; std::ostream *m_stream;
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -7,7 +7,7 @@
#include "argnames.h" #include "argnames.h"
#include <functional> #include <functional>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
Filter::Filter(BufferedTransformation *attachment) Filter::Filter(BufferedTransformation *attachment)
: m_attachment(attachment), m_continueAt(0) : m_attachment(attachment), m_continueAt(0)
@@ -605,4 +605,4 @@ unsigned int StringStore::CopyRangeTo2(BufferedTransformation &target, unsigned
return blockedBytes; return blockedBytes;
} }
NAMESPACE_END }
+2 -2
View File
@@ -8,7 +8,7 @@
#include "queue.h" #include "queue.h"
#include "algparam.h" #include "algparam.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
/// provides an implementation of BufferedTransformation's attachment interface /// provides an implementation of BufferedTransformation's attachment interface
class Filter : public BufferedTransformation, public NotCopyable class Filter : public BufferedTransformation, public NotCopyable
@@ -532,6 +532,6 @@ public:
: SourceTemplate<StringStore>(attachment) {SourceInitialize(pumpAll, MakeParameters("InputBuffer", ConstByteArrayParameter(string)));} : SourceTemplate<StringStore>(attachment) {SourceInitialize(pumpAll, MakeParameters("InputBuffer", ConstByteArrayParameter(string)));}
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -20,7 +20,7 @@
#include "algebra.cpp" #include "algebra.cpp"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
bool FunctionAssignIntToInteger(const std::type_info &valueType, void *pInteger, const void *pInt) bool FunctionAssignIntToInteger(const std::type_info &valueType, void *pInteger, const void *pInt)
{ {
@@ -3914,4 +3914,4 @@ const Integer& MontgomeryRepresentation::MultiplicativeInverse(const Integer &a)
template class AbstractRing<Integer>; template class AbstractRing<Integer>;
NAMESPACE_END }
+3 -3
View File
@@ -21,7 +21,7 @@
# endif # endif
#endif #endif
*/ */
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
#ifdef SSE2_INTRINSICS_AVAILABLE #ifdef SSE2_INTRINSICS_AVAILABLE
template <class T> template <class T>
@@ -412,13 +412,13 @@ inline CryptoPP::Integer operator/(const CryptoPP::Integer &a, CryptoPP::word b)
//! //!
inline CryptoPP::word operator%(const CryptoPP::Integer &a, CryptoPP::word b) {return a.Modulo(b);} inline CryptoPP::word operator%(const CryptoPP::Integer &a, CryptoPP::word b) {return a.Modulo(b);}
NAMESPACE_END }
NAMESPACE_BEGIN(std) NAMESPACE_BEGIN(std)
template<> inline void swap(CryptoPP::Integer &a, CryptoPP::Integer &b) template<> inline void swap(CryptoPP::Integer &a, CryptoPP::Integer &b)
{ {
a.swap(b); a.swap(b);
} }
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -4,7 +4,7 @@
#include "iterhash.h" #include "iterhash.h"
#include "misc.h" #include "misc.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
template <class T, class BASE> template <class T, class BASE>
IteratedHashBase<T, BASE>::IteratedHashBase(unsigned int blockSize, IteratedHashBase<T, BASE>::IteratedHashBase(unsigned int blockSize,
@@ -120,4 +120,4 @@ template class IteratedHashBase<word64, MessageAuthenticationCode>;
template class IteratedHashBase<word32, HashTransformation>; template class IteratedHashBase<word32, HashTransformation>;
template class IteratedHashBase<word32, MessageAuthenticationCode>; template class IteratedHashBase<word32, MessageAuthenticationCode>;
NAMESPACE_END }
+2 -2
View File
@@ -5,7 +5,7 @@
#include "secblock.h" #include "secblock.h"
#include "misc.h" #include "misc.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
template <class T, class BASE> template <class T, class BASE>
class IteratedHashBase : public BASE class IteratedHashBase : public BASE
@@ -116,6 +116,6 @@ template <class T, class B, class BASE> void IteratedHashBase2<T, B, BASE>::Hash
} }
} }
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -4,7 +4,7 @@
#include "misc.h" #include "misc.h"
#include "words.h" #include "words.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
byte OAEP_P_DEFAULT[1]; byte OAEP_P_DEFAULT[1];
@@ -80,4 +80,4 @@ unsigned long Crop(unsigned long value, unsigned int size)
return value; return value;
} }
NAMESPACE_END }
+2 -2
View File
@@ -12,7 +12,7 @@
#include <stdlib.h> #include <stdlib.h>
#endif #endif
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
// ************** compile-time assertion *************** // ************** compile-time assertion ***************
@@ -520,6 +520,6 @@ inline T SafeLeftShift(T value)
return SafeShifter<(bits>=(8*sizeof(T)))>::LeftShift(value, bits); return SafeShifter<(bits>=(8*sizeof(T)))>::LeftShift(value, bits);
} }
NAMESPACE_END }
#endif // MISC_H #endif // MISC_H
+2 -2
View File
@@ -8,7 +8,7 @@
#include "integer.h" #include "integer.h"
#include "algebra.h" #include "algebra.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! . //! .
class ModularArithmetic : public AbstractRing<Integer> class ModularArithmetic : public AbstractRing<Integer>
@@ -145,6 +145,6 @@ private:
mutable SecAlignedWordBlock workspace; mutable SecAlignedWordBlock workspace;
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -3,7 +3,7 @@
#include "pch.h" #include "pch.h"
#include "mqueue.h" #include "mqueue.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
MessageQueue::MessageQueue(unsigned int nodeSize) MessageQueue::MessageQueue(unsigned int nodeSize)
: m_queue(nodeSize), m_lengths(1, 0U), m_messageCounts(1, 0U) : m_queue(nodeSize), m_lengths(1, 0U), m_messageCounts(1, 0U)
@@ -68,4 +68,4 @@ const byte * MessageQueue::Spy(unsigned int &contiguousSize) const
// ************************************************************* // *************************************************************
NAMESPACE_END }
+3 -3
View File
@@ -5,7 +5,7 @@
#include "filters.h" #include "filters.h"
#include <deque> #include <deque>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! Message Queue //! Message Queue
class MessageQueue : public AutoSignaling<BufferedTransformation> class MessageQueue : public AutoSignaling<BufferedTransformation>
@@ -61,13 +61,13 @@ private:
}; };
NAMESPACE_END }
NAMESPACE_BEGIN(std) NAMESPACE_BEGIN(std)
template<> inline void swap(CryptoPP::MessageQueue &a, CryptoPP::MessageQueue &b) template<> inline void swap(CryptoPP::MessageQueue &a, CryptoPP::MessageQueue &b)
{ {
a.swap(b); a.swap(b);
} }
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -8,7 +8,7 @@
#include <math.h> #include <math.h>
#include <vector> #include <vector>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
const unsigned int maxPrimeTableSize = 3511; // last prime 32719 const unsigned int maxPrimeTableSize = 3511; // last prime 32719
const word lastSmallPrime = 32719; const word lastSmallPrime = 32719;
@@ -730,4 +730,4 @@ unsigned int DiscreteLogWorkFactor(unsigned int n)
} }
NAMESPACE_END }
+2 -2
View File
@@ -6,7 +6,7 @@
#include "integer.h" #include "integer.h"
#include "algparam.h" #include "algparam.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
// export a table of small primes // export a table of small primes
extern const unsigned int maxPrimeTableSize; extern const unsigned int maxPrimeTableSize;
@@ -104,6 +104,6 @@ bool SolveModularQuadraticEquation(Integer &r1, Integer &r2, const Integer &a, c
unsigned int DiscreteLogWorkFactor(unsigned int bitlength); unsigned int DiscreteLogWorkFactor(unsigned int bitlength);
unsigned int FactoringWorkFactor(unsigned int bitlength); unsigned int FactoringWorkFactor(unsigned int bitlength);
NAMESPACE_END }
#endif #endif
+3 -3
View File
@@ -5,7 +5,7 @@
#include "asn.h" #include "asn.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
NAMESPACE_BEGIN(ASN1) NAMESPACE_BEGIN(ASN1)
@@ -105,8 +105,8 @@ DEFINE_OID(2, joint_iso_ccitt)
DEFINE_OID(nist_hashalgs()+2, id_sha384) DEFINE_OID(nist_hashalgs()+2, id_sha384)
DEFINE_OID(nist_hashalgs()+3, id_sha512) DEFINE_OID(nist_hashalgs()+3, id_sha512)
NAMESPACE_END }
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -21,7 +21,7 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
#if defined(NONBLOCKING_RNG_AVAILABLE) || defined(BLOCKING_RNG_AVAILABLE) #if defined(NONBLOCKING_RNG_AVAILABLE) || defined(BLOCKING_RNG_AVAILABLE)
OS_RNG_Err::OS_RNG_Err(const std::string &operation) OS_RNG_Err::OS_RNG_Err(const std::string &operation)
@@ -99,6 +99,6 @@ void NonblockingRng::GenerateBlock(byte *output, unsigned int size)
#endif #endif
} }
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -10,7 +10,7 @@
#include "cryptlib.h" #include "cryptlib.h"
#include "filters.h" #include "filters.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! Exception class for Operating-System Random Number Generator. //! Exception class for Operating-System Random Number Generator.
class OS_RNG_Err : public Exception class OS_RNG_Err : public Exception
@@ -55,6 +55,6 @@ protected:
#endif #endif
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -4,7 +4,7 @@
#include "pkcspad.h" #include "pkcspad.h"
#include <assert.h> #include <assert.h>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
template<> const byte PKCS_DigestDecoration<SHA>::decoration[] = {0x30,0x21,0x30,0x09,0x06,0x05,0x2B,0x0E,0x03,0x02,0x1A,0x05,0x00,0x04,0x14}; template<> const byte PKCS_DigestDecoration<SHA>::decoration[] = {0x30,0x21,0x30,0x09,0x06,0x05,0x2B,0x0E,0x03,0x02,0x1A,0x05,0x00,0x04,0x14};
template<> const unsigned int PKCS_DigestDecoration<SHA>::length = sizeof(PKCS_DigestDecoration<SHA>::decoration); template<> const unsigned int PKCS_DigestDecoration<SHA>::length = sizeof(PKCS_DigestDecoration<SHA>::decoration);
@@ -41,4 +41,4 @@ void PKCS1v15_SignatureMessageEncodingMethod::ComputeMessageRepresentative(Rando
hash.Final(pDigest); hash.Final(pDigest);
} }
NAMESPACE_END }
+2 -2
View File
@@ -4,7 +4,7 @@
#include "cryptlib.h" #include "cryptlib.h"
#include "pubkey.h" #include "pubkey.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! <a href="http://www.weidai.com/scan-mirror/ca.html#cem_PKCS1-1.5">EME-PKCS1-v1_5</a> //! <a href="http://www.weidai.com/scan-mirror/ca.html#cem_PKCS1-1.5">EME-PKCS1-v1_5</a>
@@ -46,6 +46,6 @@ struct PKCS1v15 : public SignatureStandard
class SHA; class SHA;
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -3,7 +3,7 @@
#include "pch.h" #include "pch.h"
#include "pubkey.h" #include "pubkey.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
void P1363_MGF1KDF2_Common(HashTransformation &hash, byte *output, unsigned int outputLength, const byte *input, unsigned int inputLength, bool mask, unsigned int counterStart) void P1363_MGF1KDF2_Common(HashTransformation &hash, byte *output, unsigned int outputLength, const byte *input, unsigned int inputLength, bool mask, unsigned int counterStart)
{ {
@@ -99,4 +99,4 @@ DecodingResult TF_VerifierBase::RecoverAndRestart(byte *recoveredMessage, PK_Mes
return result; return result;
} }
NAMESPACE_END }
+2 -2
View File
@@ -42,7 +42,7 @@
// VC60 workaround: this macro is defined in shlobj.h and conflicts with a template parameter used in this file // VC60 workaround: this macro is defined in shlobj.h and conflicts with a template parameter used in this file
#undef INTERFACE #undef INTERFACE
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
Integer NR_EncodeDigest(unsigned int modulusBits, const byte *digest, unsigned int digestLen); Integer NR_EncodeDigest(unsigned int modulusBits, const byte *digest, unsigned int digestLen);
Integer DSA_EncodeDigest(unsigned int modulusBits, const byte *digest, unsigned int digestLen); Integer DSA_EncodeDigest(unsigned int modulusBits, const byte *digest, unsigned int digestLen);
@@ -597,6 +597,6 @@ public:
typedef PK_FinalTemplate<TF_VerifierImpl<SchemeOptions> > Verifier; typedef PK_FinalTemplate<TF_VerifierImpl<SchemeOptions> > Verifier;
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -4,7 +4,7 @@
#include "queue.h" #include "queue.h"
#include "filters.h" #include "filters.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
// this class for use by ByteQueue only // this class for use by ByteQueue only
class ByteQueueNode class ByteQueueNode
@@ -515,4 +515,4 @@ unsigned int ByteQueue::Walker::CopyRangeTo2(BufferedTransformation &target, uns
return blockedBytes; return blockedBytes;
} }
NAMESPACE_END }
+3 -3
View File
@@ -6,7 +6,7 @@
#include "simple.h" #include "simple.h"
//#include <algorithm> //#include <algorithm>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
/** The queue is implemented as a linked list of byte arrays, but you don't need to /** The queue is implemented as a linked list of byte arrays, but you don't need to
know about that. So just ignore this next line. :) */ know about that. So just ignore this next line. :) */
@@ -116,13 +116,13 @@ private:
ByteQueue &m_bq; ByteQueue &m_bq;
}; };
NAMESPACE_END }
NAMESPACE_BEGIN(std) NAMESPACE_BEGIN(std)
template<> inline void swap(CryptoPP::ByteQueue &a, CryptoPP::ByteQueue &b) template<> inline void swap(CryptoPP::ByteQueue &a, CryptoPP::ByteQueue &b)
{ {
a.swap(b); a.swap(b);
} }
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -10,7 +10,7 @@
#include "algparam.h" #include "algparam.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
OID RSAFunction::GetAlgorithmID() const OID RSAFunction::GetAlgorithmID() const
@@ -232,4 +232,4 @@ void InvertibleRSAFunction::AssignFrom(const NameValuePairs &source)
; ;
} }
NAMESPACE_END }
+2 -2
View File
@@ -10,7 +10,7 @@
#include "integer.h" #include "integer.h"
#include "asn.h" #include "asn.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! . //! .
class RSAFunction : public TrapdoorFunction, public X509PublicKey class RSAFunction : public TrapdoorFunction, public X509PublicKey
@@ -118,6 +118,6 @@ struct RSASS : public TF_SS<STANDARD, H, RSA>
typedef RSASS<PKCS1v15, SHA>::Signer RSASSA_PKCS1v15_SHA_Signer; typedef RSASS<PKCS1v15, SHA>::Signer RSASSA_PKCS1v15_SHA_Signer;
typedef RSASS<PKCS1v15, SHA>::Verifier RSASSA_PKCS1v15_SHA_Verifier; typedef RSASS<PKCS1v15, SHA>::Verifier RSASSA_PKCS1v15_SHA_Verifier;
NAMESPACE_END }
#endif #endif
+3 -3
View File
@@ -8,7 +8,7 @@
#include <string.h> // CodeWarrior doesn't have memory.h #include <string.h> // CodeWarrior doesn't have memory.h
#include <assert.h> #include <assert.h>
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
// ************** secure memory allocation *************** // ************** secure memory allocation ***************
@@ -365,7 +365,7 @@ inline bool operator==(const CryptoPP::AllocatorWithCleanup<T>&, const CryptoPP:
template<class T, class U> template<class T, class U>
inline bool operator!=(const CryptoPP::AllocatorWithCleanup<T>&, const CryptoPP::AllocatorWithCleanup<U>&) {return (false);} inline bool operator!=(const CryptoPP::AllocatorWithCleanup<T>&, const CryptoPP::AllocatorWithCleanup<U>&) {return (false);}
NAMESPACE_END }
NAMESPACE_BEGIN(std) NAMESPACE_BEGIN(std)
template <class T, class A> template <class T, class A>
@@ -383,6 +383,6 @@ __stl_alloc_rebind(CryptoPP::AllocatorWithCleanup<_Tp1>& __a, const _Tp2*)
} }
#endif #endif
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -9,7 +9,7 @@
#include "misc.h" #include "misc.h"
#include "simple.h" #include "simple.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
//! . //! .
template <unsigned int N> template <unsigned int N>
@@ -105,6 +105,6 @@ struct SymmetricCipherDocumentation
typedef SymmetricCipher Decryption; typedef SymmetricCipher Decryption;
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -7,7 +7,7 @@
#include "sha.h" #include "sha.h"
#include "misc.h" #include "misc.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
void SHA::Init() void SHA::Init()
{ {
@@ -80,4 +80,4 @@ void SHA::Transform(word32 *state, const word32 *data)
// ************************************************************* // *************************************************************
NAMESPACE_END }
+2 -2
View File
@@ -3,7 +3,7 @@
#include "iterhash.h" #include "iterhash.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
/// <a href="http://www.weidai.com/scan-mirror/md.html#SHA-1">SHA-1</a> /// <a href="http://www.weidai.com/scan-mirror/md.html#SHA-1">SHA-1</a>
class SHA : public IteratedHashWithStaticTransform<word32, BigEndian, 64, SHA> class SHA : public IteratedHashWithStaticTransform<word32, BigEndian, 64, SHA>
@@ -20,6 +20,6 @@ protected:
typedef SHA SHA1; typedef SHA SHA1;
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -9,7 +9,7 @@
#include "cryptlib.h" #include "cryptlib.h"
#include "misc.h" #include "misc.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
template <class BASE, class ALGORITHM_INFO = BASE> template <class BASE, class ALGORITHM_INFO = BASE>
class AlgorithmImpl : public BASE class AlgorithmImpl : public BASE
@@ -185,6 +185,6 @@ public:
{return 0;} {return 0;}
}; };
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -3,7 +3,7 @@
#include "config.h" #include "config.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
template<class T> class member_ptr template<class T> class member_ptr
{ {
@@ -40,6 +40,6 @@ protected:
template <class T> member_ptr<T>::~member_ptr() {delete m_p;} template <class T> member_ptr<T>::~member_ptr() {delete m_p;}
template <class T> void member_ptr<T>::reset(T *p) {delete m_p; m_p = p;} template <class T> void member_ptr<T>::reset(T *p) {delete m_p; m_p = p;}
NAMESPACE_END }
#endif #endif
+2 -2
View File
@@ -3,7 +3,7 @@
#include "misc.h" #include "misc.h"
NAMESPACE_BEGIN(CryptoPP) namespace CryptoPP {
inline unsigned int CountWords(const word *X, unsigned int N) inline unsigned int CountWords(const word *X, unsigned int N)
{ {
@@ -98,6 +98,6 @@ inline void ShiftWordsRightByWords(word *r, unsigned int n, unsigned int shiftWo
} }
} }
NAMESPACE_END }
#endif #endif