3.7.2.1 Crypto_Hash_Ripemd160_Digest
crypto_Hash_Status_E Crypto_Hash_Ripemd160_Digest(
crypto_HandlerType_E ripedmd160Handler_en,
uint8_t *ptr_data,
uint32_t dataLen,
uint8_t *ptr_digest,
uint32_t ripemdSessionId
);
Description
This API performs hash generation RIPEMD160 algorithms in a single step without initializing.
Parameters
No. | Argument Type | Argument Name | Type | Description |
---|---|---|---|---|
1 | crypto_HandlerType_E | ripedmd160Handler_en | Input | Enum to crypto operation handler i.e., SW, HW |
2 | uint8_t* | ptr_data | Input | Input data which digest needs to calculate |
3 | uint32_t | dataLen | Input | Length of the input data in number of bytes |
4 | uint8_t* | ptr_digest | Output | Pointer to store calculated digest |
5 | uint32_t | ripemdSessionId | 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. |
Example
#define sessionID 1
crypto_Hash_Status_E status;
crypto_HandlerType_E handlerType_en = CRYPTO_HANDLER_HW_INTERNAL;
uint8_t inputData[32] = {/*data*/};
uint32_t dataLen = sizeof(inputData);
uint8_t digest[64];
status = Crypto_Hash_Ripemd160_Digest(
handlerType_en,
inputData,
dataLen,
digest,
sessionID
);