comparison mupdf-source/thirdparty/jbig2dec/sha1.h @ 2:b50eed0cc0ef upstream

ADD: MuPDF v1.26.7: the MuPDF source as downloaded by a default build of PyMuPDF 1.26.4. The directory name has changed: no version number in the expanded directory now.
author Franz Glasner <fzglas.hg@dom66.de>
date Mon, 15 Sep 2025 11:43:07 +0200
parents
children
comparison
equal deleted inserted replaced
1:1d09e1dec1d9 2:b50eed0cc0ef
1 /* public api for steve reid's public domain SHA-1 implementation */
2 /* this file is in the public domain */
3
4 #ifndef __SHA1_H
5 #define __SHA1_H
6
7 #ifdef __cplusplus
8 extern "C"
9 {
10 #endif
11
12 typedef struct {
13 uint32_t state[5];
14 uint32_t count[2];
15 uint8_t buffer[64];
16 } SHA1_CTX;
17
18 #define SHA1_DIGEST_SIZE 20
19
20 void SHA1_Init(SHA1_CTX *context);
21 void SHA1_Update(SHA1_CTX *context, const uint8_t *data, const size_t len);
22 void SHA1_Final(SHA1_CTX *context, uint8_t digest[SHA1_DIGEST_SIZE]);
23
24 #ifdef __cplusplus
25 }
26 #endif
27
28 #endif /* __SHA1_H */