# MATH_CalcMD5

## C Specification

      #include <nitro/math/dgt.h>

      static inline void MATH_CalcMD5( void* digest, const void* data, u32 dataLength );

## Arguments

digest | Pointer to the memory location that holds the calculated MD5 value.
data | Pointer to the input data
dataLength | Size of the input data

## Return Values

None.

## Description

This function calculates MD5. The length of the generated MD5 value is 128 bits, or `MATH_MD5_DIGEST_SIZE (= 16)` bytes. Use the "digest" argument to pass an area that can store a value of this size. Any size and alignment position can be used for the input data.
This is a utility function that successively calls `MATH_MD5Init`, `MATH_MD5Update`, and `MATH_MD5GetHash`. Internally, the `MATHMD5Context` structure is allocated to the stack, so make sure that you have sufficient stack when calling the function. MD5 is an algorithm to find the message digest value. For details, see RFC (Request For Comments) 1321, which is published by IETF (The Internet Engineering Task Force).

## See Also

MATH_CalcSHA1

## Revision History

04/12/2005 Initial version.

CONFIDENTIAL