MD5.h 648 B

12345678910111213141516171819202122232425
  1. #ifndef __MD5_H__
  2. #define __MD5_H__
  3. /*
  4. ===============================================================================
  5. Calculates a checksum for a block of data
  6. using the MD5 message-digest algorithm.
  7. ===============================================================================
  8. */
  9. struct MD5_CTX {
  10. unsigned int state[4];
  11. unsigned int bits[2];
  12. unsigned char in[64];
  13. };
  14. void MD5_Init( MD5_CTX *ctx );
  15. void MD5_Update( MD5_CTX *context, unsigned char const *input, size_t inputLen );
  16. void MD5_Final( MD5_CTX *context, unsigned char digest[16] );
  17. unsigned int MD5_BlockChecksum( const void *data, size_t length );
  18. #endif /* !__MD5_H__ */