Improve some sieve-related translations
[claws.git] / src / common / md5.h
blobbf82fd7351a982a1a3abf0897530ce9b0c1b463c
1 /* md5.h - MD5 Message-Digest Algorithm
2 * Copyright (C) 1995, 1996, 1998, 1999 Free Software Foundation, Inc.
4 * according to the definition of MD5 in RFC 1321 from April 1992.
5 * NOTE: This is *not* the same file as the one from glibc
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the
9 * Free Software Foundation; either version 3, or (at your option) any
10 * later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
21 #ifndef _MD5_HDR_
22 #define _MD5_HDR_
24 #include "utils.h"
26 #ifndef HAVE_U32_TYPEDEF
27 #undef u32 /* maybe there is a macro with this name */
28 typedef guint32 u32;
29 #define HAVE_U32_TYPEDEF
30 #endif
32 typedef struct { /* Hmm, should be private */
33 u32 A,B,C,D;
34 u32 nblocks;
35 unsigned char buf[64];
36 int count;
37 int finalized;
38 } MD5_CONTEXT;
40 void md5_hex_digest(char *hexdigest, const unsigned char *s);
41 int md5_hex_digest_file(char *hexdigest, const unsigned char *file);
42 void md5_hex_hmac(char *hexdigest,
43 const unsigned char* text, int text_len,
44 const unsigned char* key, int key_len);
46 #endif /* _MD5_HDR_ */