summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2017-06-03 12:06:35 +0100
committerChris Wilson <chris+github@qwirx.com>2018-01-01 16:13:16 +0000
commit3db0438644b10370293d9b2f3bd8457561e2c9f8 (patch)
tree387b7b54d15fa2f646366a51ada52034ea26fa6f /lib
parent01755b62f6542d25a885a4fe26ce9fc1ac6decaf (diff)
Replace RAND_pseudo_bytes with RAND_bytes
RAND_pseudo_bytes is less secure and is now deprecated. (cherry picked from commit f449986b68bd12c18d742c91b625779ae75b11a2)
Diffstat (limited to 'lib')
-rw-r--r--lib/crypto/Random.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/crypto/Random.cpp b/lib/crypto/Random.cpp
index 1d6a07f0..c34a6eea 100644
--- a/lib/crypto/Random.cpp
+++ b/lib/crypto/Random.cpp
@@ -50,7 +50,7 @@ void Random::Initialise()
// --------------------------------------------------------------------------
void Random::Generate(void *pOutput, int Length)
{
- if(RAND_pseudo_bytes((uint8_t*)pOutput, Length) == -1)
+ if(RAND_bytes((uint8_t*)pOutput, Length) == -1)
{
THROW_EXCEPTION(CipherException, PseudoRandNotAvailable)
}