diff options
Diffstat (limited to 'src/crypto/rand/internal.h')
-rw-r--r-- | src/crypto/rand/internal.h | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/crypto/rand/internal.h b/src/crypto/rand/internal.h index 1cca7f3..f35abbb 100644 --- a/src/crypto/rand/internal.h +++ b/src/crypto/rand/internal.h @@ -24,13 +24,10 @@ extern "C" { * system. */ void CRYPTO_sysrand(uint8_t *buf, size_t len); -/* CRYPTO_have_hwrand returns one iff |CRYPTO_hwrand| can be called to generate - * hardware entropy. */ -int CRYPTO_have_hwrand(void); - -/* CRYPTO_hwrand fills |len| bytes at |buf| with entropy from the hardware. - * This function can only be called if |CRYPTO_have_hwrand| returns one. */ -void CRYPTO_hwrand(uint8_t *buf, size_t len); +/* CRYPTO_hwrand fills |len| bytes at |buf| with entropy from the hardware. It + * returns one on success or zero on hardware failure or if hardware support is + * unavailable. */ +int CRYPTO_hwrand(uint8_t *buf, size_t len); #if defined(__cplusplus) |