md5_hash.h 859 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. /*
  2. * MD5 internal definitions
  3. * Copyright (c) 2003-2005, Jouni Malinen <j@w1.fi>
  4. *
  5. * This program is free software; you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License version 2 as
  7. * published by the Free Software Foundation.
  8. *
  9. * Alternatively, this software may be distributed under the terms of BSD
  10. * license.
  11. *
  12. * See README and COPYING for more details.
  13. */
  14. #ifndef _ROM_MD5_HASH_H_
  15. #define _ROM_MD5_HASH_H_
  16. #include <stdint.h>
  17. #ifdef __cplusplus
  18. extern "C" {
  19. #endif
  20. struct MD5Context {
  21. uint32_t buf[4];
  22. uint32_t bits[2];
  23. uint8_t in[64];
  24. };
  25. void MD5Init(struct MD5Context *context);
  26. void MD5Update(struct MD5Context *context, unsigned char const *buf, unsigned len);
  27. void MD5Final(unsigned char digest[16], struct MD5Context *context);
  28. #ifdef __cplusplus
  29. }
  30. #endif
  31. #endif /* _ROM_MD5_HASH_H_ */