blob: 28907dedc9f11ddee7cab3b3a9f2508f0d2ca946 [file] [log] [blame]
Aart Bik1a650522015-07-08 21:20:41 +00001/*
2 * See "sha1.cpp" for author info.
3 */
4#ifndef LIBDEX_SHA1_H_
5#define LIBDEX_SHA1_H_
6
7struct SHA1_CTX {
8 unsigned long state[5];
9 unsigned long count[2];
10 unsigned char buffer[64];
11};
12
13#define HASHSIZE 20
14
15void SHA1Init(SHA1_CTX* context);
16void SHA1Update(SHA1_CTX* context, const unsigned char* data,
17 unsigned long len);
18void SHA1Final(unsigned char digest[HASHSIZE], SHA1_CTX* context);
19
20#endif // LIBDEX_SHA1_H_