]> Pileus Git - ~andy/fetchmail/blob - md5.h
146ff59d3724888c0743b817d97dc5d5824a6750
[~andy/fetchmail] / md5.h
1 #ifndef MD5_H
2 #define MD5_H
3 #ifndef HEADER_MD5_H
4 /* Try to avoid clashes with OpenSSL */
5 #define HEADER_MD5_H 
6 #endif
7
8 #if SIZEOF_INT == 4
9 typedef unsigned int uint32;
10 #else
11 typedef unsigned long int uint32;
12 #endif
13
14 struct MD5Context {
15         uint32 buf[4];
16         uint32 bits[2];
17         unsigned char in[64];
18 };
19
20 void MD5Init(struct MD5Context *context);
21 void MD5Update(struct MD5Context *context, unsigned char const *buf,
22                unsigned len);
23 void MD5Final(unsigned char digest[16], struct MD5Context *context);
24 void MD5Transform(uint32 buf[4], uint32 const in[16]);
25
26 char *MD5Digest (unsigned char *s);
27
28 /*
29  * This is needed to make RSAREF happy on some MS-DOS compilers.
30  */
31 typedef struct MD5Context MD5_CTX;
32
33 #endif /* !MD5_H */