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 Type | Argument Name | Type | Description |
---|---|---|---|---|
1 | st_Crypto_Hash_Blake_Ctx* | ptr_blakeCtx_st | Output | BLAKE variant algorithm and crypto handler selection |
2 | crypto_Hash_Algo_E | blakeAlgorithm_en | Input | Hash algorithm selection |
3 | uint8_t* | ptr_blakeKey | Input | (Optional) Key needed for the BLAKE algorithm Else NULL |
4 | uint32_t | keySize | Input | (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. |
5 | uint32_t | digestSize | Input | Hash length required by user in bytes in multiples of 8 |
6 | crypto_HandlerType_E | blakeHandlerType_en | Input | Input to select the crypto engine i.e., SW library or HW crypto |
7 | uint32_t | blakeSessionId | Input | It defines the session ID, must be more than zero |
Returns
Return Type | Description |
---|---|
crypto_Hash_Status_E | Function returns the status of the API. |