Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.
 
 
 
 
 

178 linhas
7.1 KiB

  1. /**
  2. ******************************************************************************
  3. * @file stm32f4xx_hal_hash_ex.h
  4. * @author MCD Application Team
  5. * @brief Header file of HASH HAL module.
  6. ******************************************************************************
  7. * @attention
  8. *
  9. * <h2><center>&copy; Copyright (c) 2016 STMicroelectronics.
  10. * All rights reserved.</center></h2>
  11. *
  12. * This software component is licensed by ST under BSD 3-Clause license,
  13. * the "License"; You may not use this file except in compliance with the
  14. * License. You may obtain a copy of the License at:
  15. * opensource.org/licenses/BSD-3-Clause
  16. *
  17. ******************************************************************************
  18. */
  19. /* Define to prevent recursive inclusion -------------------------------------*/
  20. #ifndef STM32F4xx_HAL_HASH_EX_H
  21. #define STM32F4xx_HAL_HASH_EX_H
  22. #ifdef __cplusplus
  23. extern "C" {
  24. #endif
  25. /* Includes ------------------------------------------------------------------*/
  26. #include "stm32f4xx_hal_def.h"
  27. /** @addtogroup STM32F4xx_HAL_Driver
  28. * @{
  29. */
  30. #if defined (HASH)
  31. /** @addtogroup HASHEx
  32. * @{
  33. */
  34. /* Exported types ------------------------------------------------------------*/
  35. /* Exported constants --------------------------------------------------------*/
  36. /* Exported macro ------------------------------------------------------------*/
  37. /* Exported functions --------------------------------------------------------*/
  38. /** @addtogroup HASHEx_Exported_Functions HASH Extended Exported Functions
  39. * @{
  40. */
  41. /** @addtogroup HASHEx_Exported_Functions_Group1 HASH extended processing functions in polling mode
  42. * @{
  43. */
  44. HAL_StatusTypeDef HAL_HASHEx_SHA224_Start(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  45. uint8_t *pOutBuffer, uint32_t Timeout);
  46. HAL_StatusTypeDef HAL_HASHEx_SHA224_Accmlt(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  47. HAL_StatusTypeDef HAL_HASHEx_SHA224_Accmlt_End(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  48. uint8_t *pOutBuffer, uint32_t Timeout);
  49. HAL_StatusTypeDef HAL_HASHEx_SHA256_Start(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  50. uint8_t *pOutBuffer, uint32_t Timeout);
  51. HAL_StatusTypeDef HAL_HASHEx_SHA256_Accmlt(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  52. HAL_StatusTypeDef HAL_HASHEx_SHA256_Accmlt_End(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  53. uint8_t *pOutBuffer, uint32_t Timeout);
  54. /**
  55. * @}
  56. */
  57. /** @addtogroup HASHEx_Exported_Functions_Group2 HASH extended processing functions in interrupt mode
  58. * @{
  59. */
  60. HAL_StatusTypeDef HAL_HASHEx_SHA224_Start_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  61. uint8_t *pOutBuffer);
  62. HAL_StatusTypeDef HAL_HASHEx_SHA224_Accmlt_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  63. HAL_StatusTypeDef HAL_HASHEx_SHA224_Accmlt_End_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  64. uint8_t *pOutBuffer);
  65. HAL_StatusTypeDef HAL_HASHEx_SHA256_Start_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  66. uint8_t *pOutBuffer);
  67. HAL_StatusTypeDef HAL_HASHEx_SHA256_Accmlt_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  68. HAL_StatusTypeDef HAL_HASHEx_SHA256_Accmlt_End_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  69. uint8_t *pOutBuffer);
  70. /**
  71. * @}
  72. */
  73. /** @addtogroup HASHEx_Exported_Functions_Group3 HASH extended processing functions in DMA mode
  74. * @{
  75. */
  76. HAL_StatusTypeDef HAL_HASHEx_SHA224_Start_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  77. HAL_StatusTypeDef HAL_HASHEx_SHA224_Finish(HASH_HandleTypeDef *hhash, uint8_t *pOutBuffer, uint32_t Timeout);
  78. HAL_StatusTypeDef HAL_HASHEx_SHA256_Start_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  79. HAL_StatusTypeDef HAL_HASHEx_SHA256_Finish(HASH_HandleTypeDef *hhash, uint8_t *pOutBuffer, uint32_t Timeout);
  80. /**
  81. * @}
  82. */
  83. /** @addtogroup HASHEx_Exported_Functions_Group4 HMAC extended processing functions in polling mode
  84. * @{
  85. */
  86. HAL_StatusTypeDef HAL_HMACEx_SHA224_Start(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  87. uint8_t *pOutBuffer, uint32_t Timeout);
  88. HAL_StatusTypeDef HAL_HMACEx_SHA256_Start(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  89. uint8_t *pOutBuffer, uint32_t Timeout);
  90. /**
  91. * @}
  92. */
  93. /** @addtogroup HASHEx_Exported_Functions_Group5 HMAC extended processing functions in interrupt mode
  94. * @{
  95. */
  96. HAL_StatusTypeDef HAL_HMACEx_SHA224_Start_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  97. uint8_t *pOutBuffer);
  98. HAL_StatusTypeDef HAL_HMACEx_SHA256_Start_IT(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size,
  99. uint8_t *pOutBuffer);
  100. /**
  101. * @}
  102. */
  103. /** @addtogroup HASHEx_Exported_Functions_Group6 HMAC extended processing functions in DMA mode
  104. * @{
  105. */
  106. HAL_StatusTypeDef HAL_HMACEx_SHA224_Start_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  107. HAL_StatusTypeDef HAL_HMACEx_SHA256_Start_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  108. /**
  109. * @}
  110. */
  111. /** @addtogroup HASHEx_Exported_Functions_Group7 Multi-buffer HMAC extended processing functions in DMA mode
  112. * @{
  113. */
  114. HAL_StatusTypeDef HAL_HMACEx_MD5_Step1_2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  115. HAL_StatusTypeDef HAL_HMACEx_MD5_Step2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  116. HAL_StatusTypeDef HAL_HMACEx_MD5_Step2_3_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  117. HAL_StatusTypeDef HAL_HMACEx_SHA1_Step1_2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  118. HAL_StatusTypeDef HAL_HMACEx_SHA1_Step2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  119. HAL_StatusTypeDef HAL_HMACEx_SHA1_Step2_3_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  120. HAL_StatusTypeDef HAL_HMACEx_SHA224_Step1_2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  121. HAL_StatusTypeDef HAL_HMACEx_SHA224_Step2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  122. HAL_StatusTypeDef HAL_HMACEx_SHA224_Step2_3_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  123. HAL_StatusTypeDef HAL_HMACEx_SHA256_Step1_2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  124. HAL_StatusTypeDef HAL_HMACEx_SHA256_Step2_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  125. HAL_StatusTypeDef HAL_HMACEx_SHA256_Step2_3_DMA(HASH_HandleTypeDef *hhash, uint8_t *pInBuffer, uint32_t Size);
  126. /**
  127. * @}
  128. */
  129. /**
  130. * @}
  131. */
  132. /**
  133. * @}
  134. */
  135. #endif /* HASH*/
  136. /**
  137. * @}
  138. */
  139. #ifdef __cplusplus
  140. }
  141. #endif
  142. #endif /* STM32F4xx_HAL_HASH_EX_H */
  143. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/