/*
 * md5 signatures, written from the spec (rfc1321)
 *
 * Written May 21-22, 1998 by orc@pell.chi.il.us (david parsons)
 *
 * This code is released into the public domain.
 *
 * this module implements the following things:
 *
 *	type JH		-- md5 signature handle.
 *	JH md5_init()	-- set up for generating a digital signature.  A JH
 *			   is returned to the caller if it succeeds, 0 otherwise.
 *	void md5_put(unsigned char*, in, JH)
 *			-- run a block of data through the signature generator.
 *	char* md5_finish(JH, char*)
 *			-- when finished processing data, call this function.
 *                         It writes the signature into the 16-byte long buffer
 *                         that's passed in to it (or a static local buffer, if
 *                         none is passed.)
 *
 * EXAMPLE USAGE:
 *	JH tag = md5_init();
 *	while ((size = read(input, block, blocksize)) > 0)
 *	    md5_put(block, size, tag);
 *	signature = md5_finish(tag, 0);
 *
 * In case you're interested, `JH' stands for John Hancock, who was the
 * first to sign the American declaration of independence.
 */
#ifndef _MD5LIB_D
#define _MD5LIB_D

#ifndef _IN_MD5LIB
typedef void* JH;
#endif

extern JH md5_init();
extern void md5_put(unsigned char* buf, int len, JH target);
extern char * md5_finish(JH target, unsigned char* sigbuffer);

#endif/*_MD5LIB_D*/
