libmobi
C library for handling MOBI format ebook documents
sha1.h
Go to the documentation of this file.
1 
12 #ifndef mobi_sha1_h
13 #define mobi_sha1_h
14 
15 typedef struct {
16  uint32_t state[5];
17  uint32_t count[2];
18  uint8_t buffer[64];
19 } SHA1_CTX;
20 
21 #define SHA1_DIGEST_SIZE 20
22 
23 void SHA1_Init(SHA1_CTX *context);
24 void SHA1_Update(SHA1_CTX *context, const uint8_t *data, const size_t len);
25 void SHA1_Final(SHA1_CTX *context, uint8_t digest[SHA1_DIGEST_SIZE]);
26 
27 #endif /* sha1_h */
Definition: sha1.h:15