md5.h File Reference

Routines for computing MD5 checksums. More...

#include "int_sizes.h"

Go to the source code of this file.

Data Structures

struct  md5_context_t

Functions

void md5_buffer (const char *buffer, int length, unsigned char digest[MD5_DIGEST_LENGTH])
 Checksum a memory buffer.
int md5_file (const char *filename, unsigned char digest[MD5_DIGEST_LENGTH])
 Checksum a local file.
const char * md5_string (unsigned char digest[MD5_DIGEST_LENGTH])
 Convert an MD5 digest into a printable string.

Detailed Description

Routines for computing MD5 checksums.


Function Documentation

void md5_buffer ( const char *  buffer,
int  length,
unsigned char  digest[MD5_DIGEST_LENGTH] 
)

Checksum a memory buffer.

Note that this function produces a digest in binary form which must be converted to a human readable form with md5_string.

Parameters:
buffer Pointer to a memory buffer.
length Length of the buffer in bytes.
digest Pointer to a buffer to store the digest.
int md5_file ( const char *  filename,
unsigned char  digest[MD5_DIGEST_LENGTH] 
)

Checksum a local file.

Note that this function produces a digest in binary form which must be converted to a human readable form with md5_string.

Parameters:
filename Path to the file to checksum.
digest Pointer to a buffer to store the digest.
Returns:
One on success, zero on failure.
const char* md5_string ( unsigned char  digest[MD5_DIGEST_LENGTH]  ) 

Convert an MD5 digest into a printable string.

Parameters:
digest A binary digest returned from md5_file, md5_buffer, or chirp_reli_md5.
Returns:
A static pointer to a human readable form of the digest.
Generated on Sun Aug 14 20:55:54 2011 for cctools by  doxygen 1.6.3