satsolver  0.17.2
sha1.h
Go to the documentation of this file.
1 /* public api for steve reid's public domain SHA-1 implementation */
2 /* this file is in the public domain */
3 
4 #include <stdint.h>
5 
6 typedef struct {
7  uint32_t state[5];
8  uint32_t count[2];
9  uint8_t buffer[64];
10 } SHA1_CTX;
11 
12 #define SHA1_DIGEST_SIZE 20
13 
14 void sat_SHA1_Init(SHA1_CTX* context);
15 void sat_SHA1_Update(SHA1_CTX* context, const uint8_t* data, const size_t len);
16 void sat_SHA1_Final(SHA1_CTX* context, uint8_t digest[SHA1_DIGEST_SIZE]);