libfossil
fsl_sha1_cx Struct Reference

Holds state for SHA1 calculations. More...

#include "fossil-hash.h"

Data Fields

unsigned char buffer [64]
 
unsigned int count [2]
 
unsigned int state [5]
 

Detailed Description

Holds state for SHA1 calculations.

It is intended to be used like this:

unsigned char digest[20]
char hex[FSL_UUID_STRLEN+1];
// alternately: fsl_sha1_init(&cx)
...call fsl_sha1_update(&cx,...) any number of times to
...incrementally calculate the hash.
fsl_sha1_final(&cx, digest); // ends the calculation
// digest now contains the raw 20-byte SHA1 digest.
// hex now contains the 40-byte SHA1 + a trailing NUL

Definition at line 221 of file fossil-hash.h.

Field Documentation

unsigned char fsl_sha1_cx::buffer[64]

Definition at line 224 of file fossil-hash.h.

unsigned int fsl_sha1_cx::count[2]

Definition at line 223 of file fossil-hash.h.

unsigned int fsl_sha1_cx::state[5]

Definition at line 222 of file fossil-hash.h.


The documentation for this struct was generated from the following file: