summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>2019-11-21 00:09:11 +0100
committerDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>2019-12-15 15:25:18 +0100
commitf9fdb9d2f5a0358a3fd34b060fe23cb0eceb2e2c (patch)
tree86a9c6a1df3d2ef373002286a728a51a89569930 /include
parent2f11f2e810c7f48a001986f3eb47b3b9166e2836 (diff)
rand_lib.c: fix null pointer dereferences after RAND_get_rand_method() failure
RAND_get_rand_method() can return a NULL method pointer in the case of a malloc failure, so don't dereference it without a check. Reported-by: Zu-Ming Jiang (detected by FIFUZZ) Fixes #10480 Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/10490)
Diffstat (limited to 'include')
-rw-r--r--include/openssl/randerr.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/openssl/randerr.h b/include/openssl/randerr.h
index 70d1a17a4c..301830bccc 100644
--- a/include/openssl/randerr.h
+++ b/include/openssl/randerr.h
@@ -46,6 +46,7 @@ int ERR_load_RAND_strings(void);
# define RAND_F_RAND_POOL_BYTES_NEEDED 115
# define RAND_F_RAND_POOL_GROW 125
# define RAND_F_RAND_POOL_NEW 116
+# define RAND_F_RAND_PSEUDO_BYTES 126
# define RAND_F_RAND_WRITE_FILE 112
/*