Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: TYBLE16_simple_data_logger TYBLE16_MP3_Air
Entropy Generation
Data Structures | |
| struct | psa_drv_entropy_t |
| A struct containing all of the function pointers needed to interface to an entropy source. More... | |
Typedefs | |
| typedef psa_status_t(* | psa_drv_entropy_init_t )(void *p_context) |
| Initialize an entropy driver. | |
| typedef psa_status_t(* | psa_drv_entropy_get_bits_t )(void *p_context, uint8_t *p_buffer, uint32_t buffer_size, uint32_t *p_received_entropy_bits) |
| Get a specified number of bits from the entropy source. | |
Typedef Documentation
| typedef psa_status_t(* psa_drv_entropy_get_bits_t)(void *p_context, uint8_t *p_buffer, uint32_t buffer_size, uint32_t *p_received_entropy_bits) |
Get a specified number of bits from the entropy source.
It retrives `buffer_size` bytes of data from the entropy source. The entropy source will always fill the provided buffer to its full size, however, most entropy sources have biases, and the actual amount of entropy contained in the buffer will be less than the number of bytes. The driver will return the actual number of bytes of entropy placed in the buffer in `p_received_entropy_bytes`. A PSA Crypto API implementation will likely feed the output of this function into a Digital Random Bit Generator (DRBG), and typically has a minimum amount of entropy that it needs. To accomplish this, the PSA Crypto implementation should be designed to call this function multiple times until it has received the required amount of entropy from the entropy source.
- Parameters:
-
[in,out] p_context A hardware-specific structure containing any context information for the implementation [out] p_buffer A caller-allocated buffer for the retrieved entropy to be placed in [in] buffer_size The allocated size of `p_buffer` [out] p_received_entropy_bits The amount of entropy (in bits) actually provided in `p_buffer`
- Return values:
-
PSA_SUCCESS
Definition at line 80 of file crypto_entropy_driver.h.
| typedef psa_status_t(* psa_drv_entropy_init_t)(void *p_context) |
Initialize an entropy driver.
- Parameters:
-
[in,out] p_context A hardware-specific structure containing any context information for the implementation
- Return values:
-
PSA_SUCCESS
Definition at line 52 of file crypto_entropy_driver.h.
Generated on Tue Jul 12 2022 13:55:24 by
1.7.2