Data Structures | Defines | Functions

sha384.c File Reference

#include "wizard/studio.h"
#include "wizard/exception.h"
#include "wizard/exception-private.h"
#include "wizard/memory_.h"
#include "wizard/sha384.h"

Data Structures

struct  _SHA384Info

Defines

#define SHA384Blocksize   128
#define SHA384Digestsize   48
#define Sigma0(x)   (RotateRight(x,1) ^ RotateRight(x,8) ^ Trunc64((x) >> 7))
#define Sigma1(x)   (RotateRight(x,19) ^ RotateRight(x,61) ^ Trunc64((x) >> 6))
#define Suma0(x)   (RotateRight(x,28) ^ RotateRight(x,34) ^ RotateRight(x,39))
#define Suma1(x)   (RotateRight(x,14) ^ RotateRight(x,18) ^ RotateRight(x,41))

Functions

static void TransformSHA384 (SHA384Info *)
WizardExport SHA384InfoAcquireSHA384Info (void)
WizardExport SHA384InfoDestroySHA384Info (SHA384Info *sha_info)
WizardExport void FinalizeSHA384 (SHA384Info *sha_info)
WizardExport unsigned int GetSHA384Blocksize (const SHA384Info *sha384_info)
WizardExport const StringInfoGetSHA384Digest (const SHA384Info *sha384_info)
WizardExport unsigned int GetSHA384Digestsize (const SHA384Info *sha384_info)
WizardExport void InitializeSHA384 (SHA384Info *sha_info)
static WizardSizeType Ch (WizardSizeType x, WizardSizeType y, WizardSizeType z)
static WizardSizeType Maj (WizardSizeType x, WizardSizeType y, WizardSizeType z)
static WizardSizeType Trunc64 (WizardSizeType x)
static WizardSizeType RotateRight (WizardSizeType x, WizardSizeType n)
WizardExport void UpdateSHA384 (SHA384Info *sha_info, const StringInfo *message)

Define Documentation

#define SHA384Blocksize   128

Referenced by AcquireSHA384Info().

#define SHA384Digestsize   48
#define Sigma0 (   x  )     (RotateRight(x,1) ^ RotateRight(x,8) ^ Trunc64((x) >> 7))
#define Sigma1 (   x  )     (RotateRight(x,19) ^ RotateRight(x,61) ^ Trunc64((x) >> 6))
#define Suma0 (   x  )     (RotateRight(x,28) ^ RotateRight(x,34) ^ RotateRight(x,39))
#define Suma1 (   x  )     (RotateRight(x,14) ^ RotateRight(x,18) ^ RotateRight(x,41))

Function Documentation

WizardExport SHA384Info* AcquireSHA384Info ( void   ) 
static WizardSizeType Ch ( WizardSizeType  x,
WizardSizeType  y,
WizardSizeType  z 
) [inline, static]

Referenced by TransformSHA384().

WizardExport SHA384Info* DestroySHA384Info ( SHA384Info sha_info  ) 
WizardExport void FinalizeSHA384 ( SHA384Info sha_info  ) 
WizardExport unsigned int GetSHA384Blocksize ( const SHA384Info sha384_info  ) 
WizardExport const StringInfo* GetSHA384Digest ( const SHA384Info sha384_info  ) 
WizardExport unsigned int GetSHA384Digestsize ( const SHA384Info sha384_info  ) 
WizardExport void InitializeSHA384 ( SHA384Info sha_info  ) 
static WizardSizeType Maj ( WizardSizeType  x,
WizardSizeType  y,
WizardSizeType  z 
) [inline, static]

Referenced by TransformSHA384().

static WizardSizeType RotateRight ( WizardSizeType  x,
WizardSizeType  n 
) [static]

References Trunc64().

static void TransformSHA384 ( SHA384Info sha_info  )  [static]
static WizardSizeType Trunc64 ( WizardSizeType  x  )  [inline, static]
WizardExport void UpdateSHA384 ( SHA384Info sha_info,
const StringInfo message 
)