mirror of
https://github.com/jedisct1/libsodium.git
synced 2024-12-19 18:15:18 -07:00
One more safe arc4random() implementation
This commit is contained in:
parent
6a83cd05ec
commit
0f1c303bf1
@ -74,7 +74,7 @@ BOOLEAN NTAPI RtlGenRandom(PVOID RandomBuffer, ULONG RandomBufferLength);
|
||||
|
||||
#define INTERNAL_RANDOM_BLOCK_SIZE crypto_core_hchacha20_OUTPUTBYTES
|
||||
|
||||
#if defined(__OpenBSD__) || defined(__CloudABI__)
|
||||
#if defined(__OpenBSD__) || defined(__CloudABI__) || defined(__wasi__)
|
||||
# define HAVE_SAFE_ARC4RANDOM 1
|
||||
#endif
|
||||
#if defined(__CloudABI__) || defined(__wasm__)
|
||||
|
@ -72,7 +72,7 @@ BOOLEAN NTAPI RtlGenRandom(PVOID RandomBuffer, ULONG RandomBufferLength);
|
||||
# pragma comment(lib, "advapi32.lib")
|
||||
#endif
|
||||
|
||||
#if defined(__OpenBSD__) || defined(__CloudABI__)
|
||||
#if defined(__OpenBSD__) || defined(__CloudABI__) || defined(__wasi__)
|
||||
# define HAVE_SAFE_ARC4RANDOM 1
|
||||
#endif
|
||||
|
||||
@ -375,7 +375,7 @@ randombytes_sysrandom(void)
|
||||
return r;
|
||||
}
|
||||
|
||||
#endif /* __OpenBSD__ */
|
||||
#endif /* HAVE_SAFE_ARC4RANDOM */
|
||||
|
||||
static const char *
|
||||
randombytes_sysrandom_implementation_name(void)
|
||||
|
Loading…
Reference in New Issue
Block a user