4.6.2.1 Crypto_Hash_Md5_Init

crypto_Hash_Status_E Crypto_Hash_Md5_Init(
    st_Crypto_Hash_Md5_Ctx *ptr_md5Ctx_st, 
    crypto_HandlerType_E md5HandlerType_en, 
    uint32_t md5SessionId
    );

Description

This API is used to initiate context for MD5 algorithm.

Parameters

No.Argument TypeArgument NameTypeDescription
1st_Crypto_Hash_Md5_Ctx*ptr_md5Ctx_stOutputMd5 algorithm and crypto handler context
2crypto_HandlerType_Emd5HandlerType_enInputInput to select the crypto engine i.e., SW library or HW crypto
3uint32_tmd5SessionIdInputIt defines the session ID, must be more than zero

Returns

Return TypeDescription
crypto_Hash_Status_EFunction returns the status of the API.

Prerequisites

  • To use the HW handler, the algorithm must be enabled in Crypto v4 in MPLAB® Code Configurator.
  • To use the SW handler, the algorithm must be enabled in wolfCrypt, and linked to Crypto V4 in MPLAB® Code Configurator.

Example

Example provided in Crypto_Hash_Md5_Final.