3.5.2.2 Crypto_Hash_Blake_Init

crypto_Hash_Status_E Crypto_Hash_Blake_Init(
    st_Crypto_Hash_Blake_Ctx *ptr_blakeCtx_st, 
    crypto_Hash_Algo_E blakeAlgorithm_en, 
    uint8_t *ptr_blakeKey, 
    uint32_t keySize, 
    uint32_t digestSize, 
    crypto_HandlerType_E blakeHandlerType_e, 
    uint32_t blakeSessionId
    );

Description

This API is used to initiate context for BLAKE algorithms variants.

Parameters

No.Argument TypeArgument NameTypeDescription
1st_Crypto_Hash_Blake_Ctx*ptr_blakeCtx_stOutputBLAKE variant algorithm and crypto handler selection
2crypto_Hash_Algo_EblakeAlgorithm_enInputHash algorithm selection
3uint8_t*ptr_blakeKeyInput(Optional) Key needed for the BLAKE algorithm Else NULL
4uint32_tkeySizeInput(Optional) Key length in bytes needed for the BLAKE algorithm else 0. Maximum length of key is allowed 64 bytes for BLAKE2b and up to 32 bytes for BLAKE2s.
5uint32_tdigestSizeInputHash length required by user in bytes in multiples of 8
6crypto_HandlerType_EblakeHandlerType_enInputInput to select the crypto engine i.e., SW library or HW crypto
7uint32_tblakeSessionIdInputIt defines the session ID, must be more than zero

Returns

Return TypeDescription
crypto_Hash_Status_EFunction returns the status of the API.