summaryrefslogtreecommitdiffstats
path: root/fuzz/server.c
diff options
context:
space:
mode:
authorPauli <paul.dale@oracle.com>2020-12-10 03:04:58 +0100
committerPauli <ppzgs1@gmail.com>2021-02-23 14:24:13 +0100
commitde2ea978b5be4607c677aaefceebff39b1520e0a (patch)
tree919c1c9cc6345ee7358f9abee6eff009ad5d4e87 /fuzz/server.c
parentRAND_METHOD deprecation: tests (diff)
downloadopenssl-de2ea978b5be4607c677aaefceebff39b1520e0a.tar.xz
openssl-de2ea978b5be4607c677aaefceebff39b1520e0a.zip
RAND_METHOD deprecation: fuzzer
Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/13652)
Diffstat (limited to 'fuzz/server.c')
-rw-r--r--fuzz/server.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/fuzz/server.c b/fuzz/server.c
index c381bbfae8..6234e15ccc 100644
--- a/fuzz/server.c
+++ b/fuzz/server.c
@@ -12,7 +12,7 @@
/* Test first part of SSL server handshake. */
-/* We need to use the deprecated RSA/EC low level calls */
+/* We need to use some deprecated APIs */
#define OPENSSL_SUPPRESS_DEPRECATED
#include <time.h>
@@ -25,8 +25,6 @@
#include <openssl/err.h>
#include "fuzzer.h"
-#include "rand.inc"
-
static const uint8_t kCertificateDER[] = {
0x30, 0x82, 0x02, 0xff, 0x30, 0x82, 0x01, 0xe7, 0xa0, 0x03, 0x02, 0x01,
0x02, 0x02, 0x11, 0x00, 0xb1, 0x84, 0xee, 0x34, 0x99, 0x98, 0x76, 0xfb,
@@ -495,12 +493,12 @@ int FuzzerInitialize(int *argc, char ***argv)
{
STACK_OF(SSL_COMP) *comp_methods;
+ FuzzerSetRand();
OPENSSL_init_crypto(OPENSSL_INIT_LOAD_CRYPTO_STRINGS | OPENSSL_INIT_ASYNC, NULL);
OPENSSL_init_ssl(OPENSSL_INIT_LOAD_SSL_STRINGS, NULL);
ERR_clear_error();
CRYPTO_free_ex_index(0, -1);
idx = SSL_get_ex_data_X509_STORE_CTX_idx();
- FuzzerSetRand();
comp_methods = SSL_COMP_get_compression_methods();
if (comp_methods != NULL)
sk_SSL_COMP_sort(comp_methods);
@@ -663,4 +661,5 @@ int FuzzerTestOneInput(const uint8_t *buf, size_t len)
void FuzzerCleanup(void)
{
+ FuzzerClearRand();
}