libsodium: Needed for Dnscrypto-proxy Release 1.3.0
[tomato.git] / release / src / router / libsodium / src / libsodium / include / sodium / randombytes_sysrandom.h
blob20dab78180c4b029dc5c85d9cb6f30557e183672
2 #ifndef randombytes_sysrandom_H
3 #define randombytes_sysrandom_H
5 /*
6 * THREAD SAFETY: randombytes_sysrandom() functions are thread-safe,
7 * provided that you called sodium_init() once before using any
8 * other libsodium function.
9 */
11 #include <stddef.h>
12 #include <stdint.h>
14 #include "export.h"
16 #ifdef __cplusplus
17 extern "C" {
18 #endif
20 SODIUM_EXPORT
21 extern struct randombytes_implementation randombytes_sysrandom_implementation;
23 SODIUM_EXPORT
24 const char *randombytes_sysrandom_implementation_name(void);
26 SODIUM_EXPORT
27 uint32_t randombytes_sysrandom(void);
29 SODIUM_EXPORT
30 void randombytes_sysrandom_stir(void);
32 SODIUM_EXPORT
33 uint32_t randombytes_sysrandom_uniform(const uint32_t upper_bound);
35 SODIUM_EXPORT
36 void randombytes_sysrandom_buf(void * const buf, const size_t size);
38 SODIUM_EXPORT
39 int randombytes_sysrandom_close(void);
41 #ifdef __cplusplus
43 #endif
45 #endif