CUBRID Engine  latest
sha1.c File Reference
#include "sha1.h"
#include "error_manager.h"
#include <assert.h>
Include dependency graph for sha1.c:

Go to the source code of this file.

Macros

#define SHA1CircularShift(bits, word)
 

Functions

void SHA1ProcessMessageBlock (SHA1Context *)
 
void SHA1PadMessage (SHA1Context *)
 
void SHA1Reset (SHA1Context *context)
 
int SHA1Result (SHA1Context *context)
 
void SHA1Input (SHA1Context *context, const unsigned char *message_array, size_t length)
 
int SHA1Compute (const unsigned char *message_array, size_t length, SHA1Hash *hash)
 
int SHA1Compare (void *a, void *b)
 

Macro Definition Documentation

#define SHA1CircularShift (   bits,
  word 
)
Value:
((((word) << (bits)) & 0xFFFFFFFF) | \
((word) >> (32-(bits))))

Definition at line 49 of file sha1.c.

Referenced by SHA1ProcessMessageBlock().

Function Documentation

int SHA1Compare ( void *  a,
void *  b 
)

Definition at line 400 of file sha1.c.

References diff, SHA1Hash::h, and i.

Referenced by xcache_compare_key().

Here is the caller graph for this function:

void SHA1Input ( SHA1Context context,
const unsigned char *  message_array,
size_t  length 
)
void SHA1PadMessage ( SHA1Context context)

Definition at line 324 of file sha1.c.

References SHA1Context::Length_High, SHA1Context::Length_Low, SHA1Context::Message_Block, SHA1Context::Message_Block_Index, and SHA1ProcessMessageBlock().

Referenced by SHA1Result().

Here is the caller graph for this function:

void SHA1ProcessMessageBlock ( SHA1Context context)

Definition at line 211 of file sha1.c.

References SHA1Context::Message_Block, SHA1Context::Message_Block_Index, SHA1Context::Message_Digest, and SHA1CircularShift.

Referenced by SHA1Input(), and SHA1PadMessage().

Here is the caller graph for this function:

void SHA1Reset ( SHA1Context context)
int SHA1Result ( SHA1Context context)

Definition at line 109 of file sha1.c.

References SHA1Context::Computed, SHA1Context::Corrupted, and SHA1PadMessage().

Referenced by crypt_encrypt_sha1_printable(), and SHA1Compute().

Here is the caller graph for this function: