From 6ac1cd10ba8a1d92d3858e53a7aea2cf444adf26 Mon Sep 17 00:00:00 2001 From: Matt Caswell Date: Wed, 2 Sep 2020 16:15:06 +0100 Subject: Fix safestack issues in ssl.h We fix 3 problems with safestack: - Including an openssl header file without linking against libcrypto can cause compilation failures (even if the app does not otherwise need to link against libcrypto). See issue #8102 - Recent changes means that applications in no-deprecated builds will need to include additional macro calls in the source code for all stacks that they need to use - which is an API break. This changes avoids that necessity. - It is not possible to write code using stacks that works in both a no-deprecated and a normal build of OpenSSL. See issue #12707. Fixes #12707 Contains a partial fix for #8102. A similar PR will be needed for hash to fully fix. Reviewed-by: Richard Levitte Reviewed-by: Paul Dale (Merged from https://github.com/openssl/openssl/pull/12781) --- fuzz/client.c | 2 -- fuzz/server.c | 2 -- 2 files changed, 4 deletions(-) (limited to 'fuzz') diff --git a/fuzz/client.c b/fuzz/client.c index 01bd70a49f..2c2cd90fb8 100644 --- a/fuzz/client.c +++ b/fuzz/client.c @@ -20,8 +20,6 @@ #include "rand.inc" -DEFINE_STACK_OF(SSL_COMP) - /* unused, to avoid warning. */ static int idx; diff --git a/fuzz/server.c b/fuzz/server.c index f00029b0a9..8123c90994 100644 --- a/fuzz/server.c +++ b/fuzz/server.c @@ -24,8 +24,6 @@ #include "rand.inc" -DEFINE_STACK_OF(SSL_COMP) - 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, -- cgit v1.2.3