[#RAND_bytes_ex] = RAND_bytes_ex :mrdocs: Fill a buffer with public CSPRNG bytes using a library context and strength. == Synopsis Declared in `<openssl/rand.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int RAND_bytes_ex( xref:OSSL_LIB_CTX.adoc[OSSL_LIB_CTX]* ctx, unsigned char* buf, size_t num, unsigned int strength); ---- == Return Value 1 on success, ‐1 if not supported by the current RAND method, or 0 on other failure. == Parameters [cols="1,4"] |=== | Name| Description | *ctx* | Library context whose public DRBG is used, or NULL for the default. | *buf* | Buffer that receives `num` random bytes. | *num* | Number of bytes to generate. | *strength* | Requested security strength in bits for the generated bytes. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#