Drizzled Public API Documentation

sha1.h
Go to the documentation of this file.
00001 #pragma once
00002 
00008 #ifdef  __cplusplus
00009 extern "C" {
00010 #endif
00011 
00024 #define SHA1_BLOCK_LENGTH   64
00025 #define SHA1_DIGEST_LENGTH    20
00026 #define SHA1_DIGEST_STRING_LENGTH (SHA1_DIGEST_LENGTH * 2 + 1)
00027 
00028 typedef struct {
00029     uint32_t state[5];
00030     uint64_t count;
00031     uint8_t buffer[SHA1_BLOCK_LENGTH];
00032 } SHA1_CTX;
00033 
00034 void SHA1Init(SHA1_CTX *);
00035 void SHA1Pad(SHA1_CTX *);
00036 void SHA1Transform(uint32_t [5], const uint8_t [SHA1_BLOCK_LENGTH]);
00037 void SHA1Update(SHA1_CTX *, const uint8_t *, size_t);
00038 void SHA1Final(uint8_t [SHA1_DIGEST_LENGTH], SHA1_CTX *);
00039 
00042 #ifdef  __cplusplus
00043 }
00044 #endif