meillo@162: /* meillo@162: * This is an OpenSSL-compatible implementation of the RSA Data Security, meillo@162: * Inc. MD5 Message-Digest Algorithm (RFC 1321). meillo@162: * meillo@162: * Written by Solar Designer in 2001, and placed meillo@162: * in the public domain. There's absolutely no warranty. meillo@162: * meillo@162: * See md5.c for more information. meillo@0: */ meillo@0: meillo@162: #ifdef HAVE_OPENSSL meillo@162: #include meillo@162: #elif !defined(_MD5_H) meillo@162: #define _MD5_H meillo@0: meillo@162: /* Any 32-bit or wider unsigned integer data type will do */ meillo@163: typedef unsigned long MD5_u32plus; meillo@0: meillo@0: typedef struct { meillo@162: MD5_u32plus lo, hi; meillo@162: MD5_u32plus a, b, c, d; meillo@162: unsigned char buffer[64]; meillo@162: MD5_u32plus block[16]; meillo@0: } MD5_CTX; meillo@0: meillo@162: extern void MD5_Init(MD5_CTX *ctx); meillo@162: extern void MD5_Update(MD5_CTX *ctx, void *data, unsigned long size); meillo@162: extern void MD5_Final(unsigned char *result, MD5_CTX *ctx); meillo@162: meillo@162: #endif