From 3db0438644b10370293d9b2f3bd8457561e2c9f8 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Sat, 3 Jun 2017 12:06:35 +0100 Subject: Replace RAND_pseudo_bytes with RAND_bytes RAND_pseudo_bytes is less secure and is now deprecated. (cherry picked from commit f449986b68bd12c18d742c91b625779ae75b11a2) --- lib/crypto/Random.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/crypto') 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) } -- cgit v1.2.3