blob: 5c5acc390e8397ea56f91e507c3f5deef9f5c2a2 [file] [log] [blame]
Ilja H. Friedel8faad302011-04-26 14:40:49 -07001// Copyright 2007 Google Inc. All Rights Reserved.
2// Author: liuli@google.com (Liu Li)
3// copied from chromium/src/breakpad/src/common/md5.h
4
5#ifndef COMMON_MD5_H__
6#define COMMON_MD5_H__
7
8#include <stdint.h>
9
10typedef uint32_t u32;
11typedef uint8_t u8;
12
13struct MD5Context {
14 u32 buf[4];
15 u32 bits[2];
16 u8 in[64];
17};
18
19#ifdef __cplusplus
20extern "C" {
21#endif // __cplusplus
22
23void MD5Init(struct MD5Context *ctx);
24
25void MD5Update(struct MD5Context *ctx, unsigned char const *buf, unsigned len);
26
27void MD5Final(unsigned char digest[16], struct MD5Context *ctx);
28
29#ifdef __cplusplus
30}
31#endif
32
33#endif // COMMON_MD5_H__