Defines

SecureHash512.cpp File Reference

#include <zeusbase/Security/SecureHash512.h>
#include <zeusbase/Security/SecurityDefines.hpp>

Defines

#define SHA512_F1(x)   (ROTR(x, 28) ^ ROTR(x, 34) ^ ROTR(x, 39))
#define SHA512_F2(x)   (ROTR(x, 14) ^ ROTR(x, 18) ^ ROTR(x, 41))
#define SHA512_F3(x)   (ROTR(x, 1) ^ ROTR(x, 8) ^ SHFR(x, 7))
#define SHA512_F4(x)   (ROTR(x, 19) ^ ROTR(x, 61) ^ SHFR(x, 6))
#define SHA512_SCR(i)   { w[i] = SHA512_F4(w[i - 2]) + w[i - 7] + SHA512_F3(w[i - 15]) + w[i - 16]; }
#define SHA512_EXP(a, b, c, d, e, f, g,h, j)

Define Documentation

#define SHA512_EXP (   a,
  b,
  c,
  d,
  e,
  f,
  g,
  h,
 
)
Value:
{                                                           \
    t1 = wv[h] + SHA512_F2(wv[e]) + CH(wv[e], wv[f], wv[g]) + m_ulSHA512_k[j] + w[j];                              \
    t2 = SHA512_F1(wv[a]) + MAJ(wv[a], wv[b], wv[c]);       \
    wv[d] += t1;                                            \
    wv[h]  = t1 + t2;                                        \
  }
#define SHA512_F1 (   x )    (ROTR(x, 28) ^ ROTR(x, 34) ^ ROTR(x, 39))
#define SHA512_F2 (   x )    (ROTR(x, 14) ^ ROTR(x, 18) ^ ROTR(x, 41))
#define SHA512_F3 (   x )    (ROTR(x, 1) ^ ROTR(x, 8) ^ SHFR(x, 7))
#define SHA512_F4 (   x )    (ROTR(x, 19) ^ ROTR(x, 61) ^ SHFR(x, 6))
#define SHA512_SCR (   i )    { w[i] = SHA512_F4(w[i - 2]) + w[i - 7] + SHA512_F3(w[i - 15]) + w[i - 16]; }
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


Written by Benjamin Hadorn http://www.xatlantis.ch.
Last change made on Sun Jan 22 2012 15:28:21