Generate random bytes from a RAND context.
Synopsis
Declared in <openssl/evp.h>
int
EVP_RAND_generate(
EVP_RAND_CTX* ctx,
unsigned char* out,
size_t outlen,
unsigned int strength,
int prediction_resistance,
unsigned char const* addin,
size_t addin_len);
Return Value
1 on success, or 0 on failure.
Parameters
Name |
Description |
ctx |
RAND context to draw from. |
out |
Buffer receiving random octets. |
outlen |
Number of bytes to generate. |
strength |
Requested security strength in bits (0 selects the context default). |
prediction_resistance |
Non‐zero to request prediction resistance / reseed before output. |
addin |
Optional additional input mixed into the generation, or NULL. |
addin_len |
Length of |
Created with MrDocs