Fill a buffer with bytes that need not be cryptographically strong (deprecated).
Declared in <openssl/rand.h>
[[deprecated]]
int
RAND_pseudo_bytes(
unsigned char* buf,
int num);
Deprecated. Use of this entity is allowed but discouraged.
Prefer RAND_bytes() for all new code.
1 if the bytes are cryptographically strong, 0 if only pseudo-random, or -1 on error.
| Name | Description |
|---|---|
| buf | Destination buffer to fill. |
| num | Number of bytes to write. |