download config.h
Language: C++
LOC: 91
Project Info
NNIM
Server: SourceForge
Type: cvs
...rge\n\nnim\nnim\GNU\crypto\
   3desval.dat
   3way.cpp
   3way.h
   3wayval.dat
   adler32.cpp
   adler32.h
   aes.h
   algebra.cpp
   algebra.h
   arc4.cpp
   arc4.h
   asn.cpp
   asn.h
   base64.cpp
   base64.h
   bench.cpp
   bench.h
   bfinit.cpp
   blowfish.cpp
   blowfish.h
   blum1024.dat
   blum2048.dat
   blum512.dat
   blumgold.cpp
   blumgold.h
   blumshub.cpp
   blumshub.h
   cast.cpp
   cast.h
   cast128v.dat
   cast256v.dat
   casts.cpp
   cbc.cpp
   cbc.h
   cbcmac.h
   channels.cpp
   channels.h
   config.h
   crc.cpp
   crc.h
   cryptest.dsp
   cryptest.dsw
   cryptest.ncb
   cryptlib.cpp
   cryptlib.dsp
   cryptlib.dsw
   cryptlib.h
   cryptlib.sln
   cryptlib.vcproj
   default.cpp
   default.h
   des.cpp
   des.h
   descert.dat
   dessp.cpp
   dh.cpp
   dh.h
   dh1024.dat
   dh2.cpp
   dh2.h
   dh2048.dat
   dh512.dat
   diamond.cpp
   diamond.dat
   diamond.h
   diamondt.cpp
   dmac.h
   dsa.cpp
   dsa.h
   dsa1024.dat
   dsa1024b.dat
   dsa512.dat
   ec2n.cpp
   ec2n.h
   eccrypto.cpp
   eccrypto.h
   ecp.cpp
   ecp.h
   elgamal.cpp
   elgamal.h
   elgc1024.dat
   elgc2048.dat
   elgc512.dat
   eprecomp.cpp
   eprecomp.h
   files.cpp
   files.h
   filters.cpp
   filters.h
   gf2_32.cpp
   gf2_32.h
   gf256.cpp
   gf256.h
   gf2n.cpp
   gf2n.h
   gost.cpp
   gost.h
   gostval.dat
   gzip.cpp
   gzip.h
   haval.cpp
   haval.h
   havalcer.dat
   hex.cpp
   hex.h
   hmac.h
   hrtimer.cpp
   hrtimer.h
   ida.cpp
   ida.h
   idea.cpp
   idea.h
   ideaval.dat
   integer.cpp
   integer.h
   iterhash.cpp
   iterhash.h
   lubyrack.h
   luc.cpp
   luc.h
   luc1024.dat
   luc2048.dat
   luc512.dat
   lucc1024.dat
   lucc512.dat
   lucd1024.dat
   lucd512.dat
   lucs1024.dat
   lucs512.dat
   Makefile.am
   Makefile.in
   mars.cpp
   mars.h
   marss.cpp
   marsval.dat
   md2.cpp
   md2.h
   md4.cpp
   md4.h
   md5.cpp
   md5.h
   md5mac.cpp
   md5mac.h
   mdc.h
   misc.cpp
   misc.h
   modarith.h
   modes.cpp
   modes.h
   modexppc.cpp
   modexppc.h
   mqueue.cpp
   mqueue.h
   mqv.cpp
   mqv.h
   mqv1024.dat
   mqv2048.dat
   mqv512.dat
   nbtheory.cpp
   nbtheory.h
   network.cpp
   network.h
   nr.cpp
   nr.h
   nr1024.dat
   nr2048.dat
   nr512.dat
   oaep.cpp
   oaep.h
   oids.h
   osrng.cpp
   osrng.h
   panama.cpp
   panama.h
   pch.cpp
   pch.h
   pkcspad.cpp
   pkcspad.h
   polynomi.cpp
   polynomi.h
   pssr.h
   pubkey.cpp
   pubkey.h
   queue.cpp
   queue.h
   rabi1024.dat
   rabi2048.dat
   rabi512.dat
   rabin.cpp
   rabin.h
   randpool.cpp
   randpool.h
   rc2.cpp
   rc2.h
   rc2val.dat
   rc5.cpp
   rc5.h
   rc5val.dat
   rc6.cpp
   rc6.h
   rc6val.dat
   rdtables.cpp
   rijndael.cpp
   rijndael.dat
   rijndael.h
   ripemd.cpp
   ripemd.h
   rng.cpp
   rng.h
   rsa.cpp
   rsa.h
   rsa1024.dat
   rsa2048.dat
   rsa400pb.dat
   rsa400pv.dat
   rsa512.dat
   rsa512a.dat
   rw.cpp
   rw.h
   rw1024.dat
   rw2048.dat
   rw512.dat
   safer.cpp
   safer.h
   saferval.dat
   sapphire.cpp
   sapphire.h
   seal.cpp
   seal.h
   secshare.cpp
   secshare.h
   serpent.cpp
   serpent.h
   serpentv.dat
   sha.cpp
   sha.h
   shark.cpp
   shark.h
   sharkbox.cpp
   sharkval.dat
   skipjack.cpp
   skipjack.dat
   skipjack.h
   smartptr.h
   socketft.cpp
   socketft.h
   square.cpp
   square.h
   squaretb.cpp
   squareva.dat
   tea.cpp
   tea.h
   test.cpp
   tftables.cpp
   tiger.cpp
   tiger.h
   tigertab.cpp
   trunhash.h
   twofish.cpp
   twofish.h
   twofishv.dat
   usage.dat
   validat1.cpp
   validat2.cpp
   validat3.cpp
   validate.h
   wake.cpp
   wake.h
   winpipes.cpp
   winpipes.h
   words.h
   xormac.h
   xtr.cpp
   xtr.h
   xtrcrypt.cpp
   xtrcrypt.h
   xtrdh171.dat
   xtrdh342.dat
   zdeflate.cpp
   zdeflate.h
   zinflate.cpp
   zinflate.h
   zlib.cpp
   zlib.h

#ifndef CRYPTOPP_CONFIG_H
#define CRYPTOPP_CONFIG_H

// ***************** Important Settings ********************

// define this if running on a big-endian CPU
#if defined(__sparc__) || defined(__hppa__) || defined(__ppc__) || defined(__mips__) || (defined(__MWERKS__) && !defined(__INTEL__))
#define IS_BIG_ENDIAN
#endif

// define this if running on a little-endian CPU
// big endian will be assumed if IS_LITTLE_ENDIAN is not defined
#ifndef IS_BIG_ENDIAN
#define IS_LITTLE_ENDIAN
#endif

// define this if you want to disable all OS-dependent features,
// such as sockets and OS-provided random number generators
// #define NO_OS_DEPENDENCE

// Define this to use features provided by Microsoft's CryptoAPI.
// Currently the only feature used is random number generation.
// This macro will be ignored if NO_OS_DEPENDENCE is defined.
#define USE_MS_CRYPTOAPI

// define this if your compiler does not support namespaces
// #define NO_NAMESPACE
#ifdef NO_NAMESPACE
#define std
#define CryptoPP
#define USING_NAMESPACE(x)
#define NAMESPACE_BEGIN(x)
#define NAMESPACE_END
#define ANONYMOUS_NAMESPACE_BEGIN
#else
#define USING_NAMESPACE(x) using namespace x;
#define NAMESPACE_BEGIN(x) namespace x {
#define ANONYMOUS_NAMESPACE_BEGIN namespace {
#define NAMESPACE_END }
#endif

// ***************** Less Important Settings ***************

// switch between different secure memory allocation mechnisms, this is the only
// one available right now
#define SECALLOC_DEFAULT

#define GZIP_OS_CODE 0

// Try this if your CPU has 256K internal cache or a slow multiply instruction
// and you want a (possibly) faster IDEA implementation using log tables
// #define IDEA_LARGECACHE

// Try this if you have a large cache or your CPU is slow manipulating
// individual bytes.
// #define DIAMOND_USE_PERMTABLE

// Define this if, for the linear congruential RNG, you want to use
// the original constants as specified in S.K. Park and K.W. Miller's
// CACM paper.
// #define LCRNG_ORIGINAL_NUMBERS

// choose which style of sockets to wrap (mostly useful for cygwin which has both)
#define PREFER_BERKELEY_STYLE_SOCKETS
// #define PREFER_WINDOWS_STYLE_SOCKETS

// ***************** Important Settings Again ********************
// But the defaults should be ok.

typedef unsigned char byte;     // moved outside namespace for Borland C++Builder 5

NAMESPACE_BEGIN(CryptoPP)

typedef unsigned short word16;
#if defined(__alpha) && !defined(_MSC_VER)
typedef unsigned int word32;
#else
typedef unsigned long word32;
#endif

#if defined(__GNUC__) || defined(__MWERKS__)
#define WORD64_AVAILABLE
typedef unsigned long long word64;
#define W64LIT(x) x##LL
#elif defined(_MSC_VER) || defined(__BCPLUSPLUS__)
#define WORD64_AVAILABLE
typedef unsigned __int64 word64;
#define W64LIT(x) x##ui64
#endif

// defined this if your CPU is not 64-bit
#if defined(WORD64_AVAILABLE) && !defined(__alpha)
#define SLOW_WORD64
#endif

// word should have the same size as your CPU registers
// dword should be twice as big as word

#if (defined(__GNUC__) && !defined(__alpha)) || defined(__MWERKS__)
typedef unsigned long word;
typedef unsigned long long dword;
#elif defined(_MSC_VER) || defined(__BCPLUSPLUS__)
typedef unsigned __int32 word;
typedef unsigned __int64 dword;
#else
typedef unsigned int word;
typedef unsigned long dword;
#endif

const unsigned int WORD_SIZE = sizeof(word);
const unsigned int WORD_BITS = WORD_SIZE * 8;

#define LOW_WORD(x) (word)(x)

union dword_union
{
	dword_union (const dword &dw) : dw(dw) {}
	dword dw;
	word w[2];
};

#ifdef IS_LITTLE_ENDIAN
#define HIGH_WORD(x) (dword_union(x).w[1])
#else
#define HIGH_WORD(x) (dword_union(x).w[0])
#endif

// if the above HIGH_WORD macro doesn't work (if you are not sure, compile it
// and run the validation tests), try this:
// #define HIGH_WORD(x) (word)((x)>>WORD_BITS)

#if defined(_MSC_VER) || defined(__BCPLUSPLUS__)
#define INTEL_INTRINSICS
#define FAST_ROTATE
#elif defined(__MWERKS__) && TARGET_CPU_PPC
#define PPC_INTRINSICS
#define FAST_ROTATE
#elif defined(__GNUC__) && defined(__i386__)
// GCC does peephole optimizations which should result in using rotate instructions
#define FAST_ROTATE
#endif

// can't use std::min or std::max in MSVC60 or Cygwin 1.1.0
template <class _Tp>
inline const _Tp& STDMIN(const _Tp& __a, const _Tp& __b) {
  return __b < __a ? __b : __a;
}

template <class _Tp>
inline const _Tp& STDMAX(const _Tp& __a, const _Tp& __b) {
  return  __a < __b ? __b : __a;
}

#ifdef _MSC_VER
// 4250: dominance
// 4660: explicitly instantiating a class that's already implicitly instantiated
// 4661: no suitable definition provided for explicit template instantiation request
// 4786: identifer was truncated in debug information
// 4355: 'this' : used in base member initializer list
// 4800: converting int to bool
#pragma warning(disable: 4250 4660 4661 4786 4355 4800)
#endif

NAMESPACE_END

#endif

About Koders | Resources | Downloads | Support | Black Duck | Submit Project | Terms of Service | DMCA | Privacy Policy | Site Map| Contact Us