Defines

sha1.cpp File Reference

Secure Hash Algorithm 1 (SHA-1). More...

#include "sha1.hpp"
#include <iomanip>
#include <sstream>
Include dependency graph for sha1.cpp:

Go to the source code of this file.

Defines

#define sha_rotl(n, x)   ( ((x) << (n)) | ((x) >> (32-(n))) )
#define sha_ch(x, y, z)   ( ((x) & (y)) | ((~(x)) & (z)) )
#define sha_parity(x, y, z)   ( (x) ^ (y) ^ (z) )
#define sha_maj(x, y, z)   ( ((x) & (y)) | ((x) & (z)) | ((y) & (z)) )

Detailed Description

Secure Hash Algorithm 1 (SHA-1).

Used to checksum the game-config / cache.

Definition in file sha1.cpp.


Define Documentation

#define sha_ch (   x,
  y,
  z 
)    ( ((x) & (y)) | ((~(x)) & (z)) )

Definition at line 37 of file sha1.cpp.

Referenced by sha1_hash::next().

#define sha_maj (   x,
  y,
  z 
)    ( ((x) & (y)) | ((x) & (z)) | ((y) & (z)) )

Definition at line 39 of file sha1.cpp.

Referenced by sha1_hash::next().

#define sha_parity (   x,
  y,
  z 
)    ( (x) ^ (y) ^ (z) )

Definition at line 38 of file sha1.cpp.

Referenced by sha1_hash::next().

#define sha_rotl (   n,
  x 
)    ( ((x) << (n)) | ((x) >> (32-(n))) )

Definition at line 36 of file sha1.cpp.

Referenced by sha1_hash::next().

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Fri May 25 2012 01:10:17 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs