summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/bind/lib/dns/dst_api.c29
-rw-r--r--usr.sbin/bind/lib/dns/dst_internal.h8
-rw-r--r--usr.sbin/bind/lib/dns/dst_openssl.h7
-rw-r--r--usr.sbin/bind/lib/dns/openssl_link.c121
-rw-r--r--usr.sbin/bind/lib/dns/openssldh_link.c11
-rw-r--r--usr.sbin/bind/lib/dns/openssldsa_link.c8
-rw-r--r--usr.sbin/bind/lib/dns/opensslrsa_link.c132
-rw-r--r--usr.sbin/bind/lib/isc/task.c8
-rw-r--r--usr.sbin/bind/lib/isc/timer.c10
9 files changed, 5 insertions, 329 deletions
diff --git a/usr.sbin/bind/lib/dns/dst_api.c b/usr.sbin/bind/lib/dns/dst_api.c
index 15d3a1e6364..a60d2037bbc 100644
--- a/usr.sbin/bind/lib/dns/dst_api.c
+++ b/usr.sbin/bind/lib/dns/dst_api.c
@@ -33,7 +33,7 @@
/*
* Principal Author: Brian Wellington
- * $Id: dst_api.c,v 1.12 2020/01/09 13:56:37 florian Exp $
+ * $Id: dst_api.c,v 1.13 2020/01/09 14:21:27 florian Exp $
*/
/*! \file */
@@ -136,7 +136,6 @@ static isc_result_t addsuffix(char *filename, int len,
return (_r); \
} while (0); \
-#if defined(OPENSSL)
static void *
default_memalloc(void *arg, size_t size) {
UNUSED(arg);
@@ -150,7 +149,6 @@ default_memfree(void *arg, void *ptr) {
UNUSED(arg);
free(ptr);
}
-#endif
isc_result_t
dst_lib_init(isc_mem_t *mctx, isc_entropy_t *ectx, unsigned int eflags) {
@@ -165,13 +163,8 @@ dst_lib_init2(isc_mem_t *mctx, isc_entropy_t *ectx,
REQUIRE(mctx != NULL);
REQUIRE(dst_initialized == ISC_FALSE);
-#if !defined(OPENSSL)
- UNUSED(engine);
-#endif
-
dst__memory_pool = NULL;
-#if defined(OPENSSL)
UNUSED(mctx);
/*
* When using --with-openssl, there seems to be no good way of not
@@ -186,12 +179,7 @@ dst_lib_init2(isc_mem_t *mctx, isc_entropy_t *ectx,
if (result != ISC_R_SUCCESS)
return (result);
isc_mem_setname(dst__memory_pool, "dst", NULL);
-#ifndef OPENSSL_LEAKS
isc_mem_setdestroycheck(dst__memory_pool, ISC_FALSE);
-#endif
-#else /* OPENSSL */
- isc_mem_attach(mctx, &dst__memory_pool);
-#endif /* OPENSSL */
if (ectx != NULL) {
isc_entropy_attach(ectx, &dst_entropy_pool);
dst_entropy_flags = eflags;
@@ -205,7 +193,6 @@ dst_lib_init2(isc_mem_t *mctx, isc_entropy_t *ectx,
RETERR(dst__hmacsha256_init(&dst_t_func[DST_ALG_HMACSHA256]));
RETERR(dst__hmacsha384_init(&dst_t_func[DST_ALG_HMACSHA384]));
RETERR(dst__hmacsha512_init(&dst_t_func[DST_ALG_HMACSHA512]));
-#ifdef OPENSSL
RETERR(dst__openssl_init(engine));
RETERR(dst__opensslrsa_init(&dst_t_func[DST_ALG_RSASHA1],
DST_ALG_RSASHA1));
@@ -228,7 +215,6 @@ dst_lib_init2(isc_mem_t *mctx, isc_entropy_t *ectx,
#ifdef HAVE_OPENSSL_ED448
RETERR(dst__openssleddsa_init(&dst_t_func[DST_ALG_ED448]));
#endif
-#endif /* if OPENSSL */
dst_initialized = ISC_TRUE;
return (ISC_R_SUCCESS);
@@ -248,9 +234,7 @@ dst_lib_destroy(void) {
for (i = 0; i < DST_MAX_ALGS; i++)
if (dst_t_func[i] != NULL && dst_t_func[i]->cleanup != NULL)
dst_t_func[i]->cleanup();
-#ifdef OPENSSL
dst__openssl_destroy();
-#endif /* if OPENSSL */
if (dst__memory_pool != NULL)
isc_mem_detach(&dst__memory_pool);
if (dst_entropy_pool != NULL)
@@ -1756,17 +1740,6 @@ algorithm_status(unsigned int alg) {
if (dst_algorithm_supported(alg))
return (ISC_R_SUCCESS);
-#if !defined(OPENSSL)
- if (alg == DST_ALG_RSAMD5 || alg == DST_ALG_RSASHA1 ||
- alg == DST_ALG_DSA || alg == DST_ALG_DH ||
- alg == DST_ALG_HMACMD5 || alg == DST_ALG_NSEC3DSA ||
- alg == DST_ALG_NSEC3RSASHA1 ||
- alg == DST_ALG_RSASHA256 || alg == DST_ALG_RSASHA512 ||
- alg == DST_ALG_ECCGOST ||
- alg == DST_ALG_ECDSA256 || alg == DST_ALG_ECDSA384 ||
- alg == DST_ALG_ED25519 || alg == DST_ALG_ED448)
- return (DST_R_NOCRYPTO);
-#endif
return (DST_R_UNSUPPORTEDALG);
}
diff --git a/usr.sbin/bind/lib/dns/dst_internal.h b/usr.sbin/bind/lib/dns/dst_internal.h
index 46f9464a2ad..0b5d78a42c6 100644
--- a/usr.sbin/bind/lib/dns/dst_internal.h
+++ b/usr.sbin/bind/lib/dns/dst_internal.h
@@ -31,7 +31,7 @@
* IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: dst_internal.h,v 1.5 2020/01/09 13:56:37 florian Exp $ */
+/* $Id: dst_internal.h,v 1.6 2020/01/09 14:21:27 florian Exp $ */
#ifndef DST_DST_INTERNAL_H
#define DST_DST_INTERNAL_H 1
@@ -56,12 +56,10 @@
#include <dst/dst.h>
-#ifdef OPENSSL
#include <openssl/err.h>
#include <openssl/evp.h>
#include <openssl/objects.h>
#include <openssl/rsa.h>
-#endif
ISC_LANG_BEGINDECLS
@@ -111,12 +109,10 @@ struct dst_key {
char *label; /*%< engine label (HSM) */
union {
void *generic;
-#ifdef OPENSSL
#if !defined(USE_EVP) || !USE_EVP
RSA *rsa;
#endif
EVP_PKEY *pkey;
-#endif
dst_hmacsha1_key_t *hmacsha1;
dst_hmacsha224_key_t *hmacsha224;
dst_hmacsha256_key_t *hmacsha256;
@@ -156,9 +152,7 @@ struct dst_context {
isc_hmacsha256_t *hmacsha256ctx;
isc_hmacsha384_t *hmacsha384ctx;
isc_hmacsha512_t *hmacsha512ctx;
-#ifdef OPENSSL
EVP_MD_CTX *evp_md_ctx;
-#endif
} ctxdata;
};
diff --git a/usr.sbin/bind/lib/dns/dst_openssl.h b/usr.sbin/bind/lib/dns/dst_openssl.h
index 03450c84c42..7c66cf65ecd 100644
--- a/usr.sbin/bind/lib/dns/dst_openssl.h
+++ b/usr.sbin/bind/lib/dns/dst_openssl.h
@@ -14,7 +14,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: dst_openssl.h,v 1.3 2019/12/17 01:46:31 sthen Exp $ */
+/* $Id: dst_openssl.h,v 1.4 2020/01/09 14:21:27 florian Exp $ */
#ifndef DST_OPENSSL_H
#define DST_OPENSSL_H 1
@@ -72,12 +72,7 @@ isc_result_t
dst__openssl_toresult3(isc_logcategory_t *category,
const char *funcname, isc_result_t fallback);
-#ifdef USE_ENGINE
-ENGINE *
-dst__openssl_getengine(const char *engine);
-#else
#define dst__openssl_getengine(x) NULL
-#endif
ISC_LANG_ENDDECLS
diff --git a/usr.sbin/bind/lib/dns/openssl_link.c b/usr.sbin/bind/lib/dns/openssl_link.c
index cfe74beebc4..ecbe2dd738d 100644
--- a/usr.sbin/bind/lib/dns/openssl_link.c
+++ b/usr.sbin/bind/lib/dns/openssl_link.c
@@ -34,7 +34,6 @@
/*
* Principal Author: Brian Wellington
*/
-#ifdef OPENSSL
#include <config.h>
@@ -53,10 +52,6 @@
#include "dst_internal.h"
#include "dst_openssl.h"
-#ifdef USE_ENGINE
-#include <openssl/engine.h>
-#endif
-
static RAND_METHOD *rm = NULL;
#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
@@ -64,10 +59,6 @@ static isc_mutex_t *locks = NULL;
static int nlocks;
#endif
-#ifdef USE_ENGINE
-static ENGINE *e = NULL;
-#endif
-
static int
entropy_get(unsigned char *buf, int num) {
isc_result_t result;
@@ -157,16 +148,8 @@ id_callback(void) {
static void *
mem_alloc(size_t size FLARG) {
-#ifdef OPENSSL_LEAKS
- void *ptr;
-
- INSIST(dst__memory_pool != NULL);
- ptr = isc__mem_allocate(dst__memory_pool, size FLARG_PASS);
- return (ptr);
-#else
INSIST(dst__memory_pool != NULL);
return (isc__mem_allocate(dst__memory_pool, size FLARG_PASS));
-#endif
}
static void
@@ -178,16 +161,8 @@ mem_free(void *ptr FLARG) {
static void *
mem_realloc(void *ptr, size_t size FLARG) {
-#ifdef OPENSSL_LEAKS
- void *rptr;
-
- INSIST(dst__memory_pool != NULL);
- rptr = isc__mem_reallocate(dst__memory_pool, ptr, size FLARG_PASS);
- return (rptr);
-#else
INSIST(dst__memory_pool != NULL);
return (isc__mem_reallocate(dst__memory_pool, ptr, size FLARG_PASS));
-#endif
}
#if OPENSSL_VERSION_NUMBER >= 0x10000000L && OPENSSL_VERSION_NUMBER < 0x10100000L
@@ -201,18 +176,9 @@ _set_thread_id(CRYPTO_THREADID *id)
isc_result_t
dst__openssl_init(const char *engine) {
isc_result_t result;
-#ifdef USE_ENGINE
- ENGINE *re;
-#else
UNUSED(engine);
-#endif
-#ifdef DNS_CRYPTO_LEAKS
- CRYPTO_malloc_debug_init();
- CRYPTO_set_mem_debug_options(V_CRYPTO_MDEBUG_ALL);
- CRYPTO_mem_ctrl(CRYPTO_MEM_CHECK_ON);
-#endif
CRYPTO_set_mem_functions(mem_alloc, mem_realloc, mem_free);
#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
nlocks = CRYPTO_num_locks();
@@ -244,63 +210,9 @@ dst__openssl_init(const char *engine) {
rm->pseudorand = entropy_getpseudo;
rm->status = entropy_status;
-#ifdef USE_ENGINE
-#if !defined(CONF_MFLAGS_DEFAULT_SECTION)
- OPENSSL_config(NULL);
-#else
- /*
- * OPENSSL_config() can only be called a single time as of
- * 1.0.2e so do the steps individually.
- */
- OPENSSL_load_builtin_modules();
- ENGINE_load_builtin_engines();
- ERR_clear_error();
- CONF_modules_load_file(NULL, NULL,
- CONF_MFLAGS_DEFAULT_SECTION |
- CONF_MFLAGS_IGNORE_MISSING_FILE);
-#endif
-
- if (engine != NULL && *engine == '\0')
- engine = NULL;
-
- if (engine != NULL) {
- e = ENGINE_by_id(engine);
- if (e == NULL) {
- result = DST_R_NOENGINE;
- goto cleanup_rm;
- }
- /* This will init the engine. */
- if (!ENGINE_set_default(e, ENGINE_METHOD_ALL)) {
- result = DST_R_NOENGINE;
- goto cleanup_rm;
- }
- }
-
- re = ENGINE_get_default_RAND();
- if (re == NULL) {
- re = ENGINE_new();
- if (re == NULL) {
- result = ISC_R_NOMEMORY;
- goto cleanup_rm;
- }
- ENGINE_set_RAND(re, rm);
- ENGINE_set_default_RAND(re);
- ENGINE_free(re);
- } else
- ENGINE_finish(re);
-#else
RAND_set_rand_method(rm);
-#endif /* USE_ENGINE */
return (ISC_R_SUCCESS);
-#ifdef USE_ENGINE
- cleanup_rm:
- if (e != NULL)
- ENGINE_free(e);
- e = NULL;
- mem_free(rm FILELINE);
- rm = NULL;
-#endif
cleanup_mutexinit:
#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
CRYPTO_set_locking_callback(NULL);
@@ -336,14 +248,6 @@ dst__openssl_destroy(void) {
#endif
OBJ_cleanup();
EVP_cleanup();
-#if defined(USE_ENGINE)
- if (e != NULL)
- ENGINE_free(e);
- e = NULL;
-#if defined(USE_ENGINE) && OPENSSL_VERSION_NUMBER >= 0x00907000L
- ENGINE_cleanup();
-#endif
-#endif
#if (OPENSSL_VERSION_NUMBER >= 0x00907000L)
CRYPTO_cleanup_all_ex_data();
#endif
@@ -355,10 +259,6 @@ dst__openssl_destroy(void) {
#endif
ERR_free_strings();
-#ifdef DNS_CRYPTO_LEAKS
- CRYPTO_mem_leaks_fp(stderr);
-#endif
-
if (locks != NULL) {
CRYPTO_set_locking_callback(NULL);
DESTROYMUTEXBLOCK(locks, nlocks);
@@ -452,25 +352,4 @@ dst__openssl_toresult3(isc_logcategory_t *category,
return (result);
}
-#if defined(USE_ENGINE)
-ENGINE *
-dst__openssl_getengine(const char *engine) {
-
- if (engine == NULL)
- return (NULL);
- if (e == NULL)
- return (NULL);
- if (strcmp(engine, ENGINE_get_id(e)) == 0)
- return (e);
- return (NULL);
-}
-#endif
-
-#else /* OPENSSL */
-
-#include <isc/util.h>
-
-EMPTY_TRANSLATION_UNIT
-
-#endif /* OPENSSL */
/*! \file */
diff --git a/usr.sbin/bind/lib/dns/openssldh_link.c b/usr.sbin/bind/lib/dns/openssldh_link.c
index 5d175cbfc44..5a4438e424d 100644
--- a/usr.sbin/bind/lib/dns/openssldh_link.c
+++ b/usr.sbin/bind/lib/dns/openssldh_link.c
@@ -33,20 +33,11 @@
/*
* Principal Author: Brian Wellington
- * $Id: openssldh_link.c,v 1.5 2020/01/09 13:52:23 florian Exp $
+ * $Id: openssldh_link.c,v 1.6 2020/01/09 14:21:27 florian Exp $
*/
-#ifdef OPENSSL
-
#include <config.h>
-#else /* OPENSSL */
-
-#include <isc/util.h>
-
-EMPTY_TRANSLATION_UNIT
-
-#endif /* OPENSSL */
/*! \file */
diff --git a/usr.sbin/bind/lib/dns/openssldsa_link.c b/usr.sbin/bind/lib/dns/openssldsa_link.c
index 156323bb09a..079be8d1d52 100644
--- a/usr.sbin/bind/lib/dns/openssldsa_link.c
+++ b/usr.sbin/bind/lib/dns/openssldsa_link.c
@@ -31,7 +31,6 @@
* IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
-#ifdef OPENSSL
#ifndef USE_EVP
#define USE_EVP 1
#endif
@@ -40,11 +39,4 @@
-#else /* OPENSSL */
-
-#include <isc/util.h>
-
-EMPTY_TRANSLATION_UNIT
-
-#endif /* OPENSSL */
/*! \file */
diff --git a/usr.sbin/bind/lib/dns/opensslrsa_link.c b/usr.sbin/bind/lib/dns/opensslrsa_link.c
index d86e7d93bb7..12672541de4 100644
--- a/usr.sbin/bind/lib/dns/opensslrsa_link.c
+++ b/usr.sbin/bind/lib/dns/opensslrsa_link.c
@@ -17,7 +17,6 @@
/*
* Principal Author: Brian Wellington
*/
-#ifdef OPENSSL
#include <config.h>
#ifndef USE_EVP
@@ -52,9 +51,6 @@
#if OPENSSL_VERSION_NUMBER > 0x00908000L
#include <openssl/bn.h>
#endif
-#ifdef USE_ENGINE
-#include <openssl/engine.h>
-#endif
/*
* Limit the size of public exponents.
@@ -1355,10 +1351,6 @@ opensslrsa_parse(dst_key_t *key, isc_lex_t *lexer, dst_key_t *pub) {
isc_result_t ret;
int i;
RSA *rsa = NULL, *pubrsa = NULL;
-#ifdef USE_ENGINE
- ENGINE *ep = NULL;
- const BIGNUM *ex = NULL;
-#endif
isc_mem_t *mctx = key->mctx;
const char *engine = NULL, *label = NULL;
#if defined(USE_ENGINE) || USE_EVP
@@ -1414,47 +1406,7 @@ opensslrsa_parse(dst_key_t *key, isc_lex_t *lexer, dst_key_t *pub) {
* See if we can fetch it.
*/
if (label != NULL) {
-#ifdef USE_ENGINE
- if (engine == NULL)
- DST_RET(DST_R_NOENGINE);
- ep = dst__openssl_getengine(engine);
- if (ep == NULL)
- DST_RET(DST_R_NOENGINE);
- pkey = ENGINE_load_private_key(ep, label, NULL, NULL);
- if (pkey == NULL)
- DST_RET(dst__openssl_toresult2(
- "ENGINE_load_private_key",
- ISC_R_NOTFOUND));
- key->engine = isc_mem_strdup(key->mctx, engine);
- if (key->engine == NULL)
- DST_RET(ISC_R_NOMEMORY);
- key->label = isc_mem_strdup(key->mctx, label);
- if (key->label == NULL)
- DST_RET(ISC_R_NOMEMORY);
- rsa = EVP_PKEY_get1_RSA(pkey);
- if (rsa == NULL)
- DST_RET(dst__openssl_toresult(DST_R_OPENSSLFAILURE));
- if (rsa_check(rsa, pubrsa) != ISC_R_SUCCESS)
- DST_RET(DST_R_INVALIDPRIVATEKEY);
- RSA_get0_key(rsa, NULL, &ex, NULL);
- if (BN_num_bits(ex) > RSA_MAX_PUBEXP_BITS)
- DST_RET(ISC_R_RANGE);
- if (pubrsa != NULL)
- RSA_free(pubrsa);
- key->key_size = EVP_PKEY_bits(pkey);
-#if USE_EVP
- key->keydata.pkey = pkey;
- RSA_free(rsa);
-#else
- key->keydata.rsa = rsa;
- EVP_PKEY_free(pkey);
-#endif
- dst__privstruct_free(&priv, mctx);
- isc_safe_memwipe(&priv, sizeof(priv));
- return (ISC_R_SUCCESS);
-#else
DST_RET(DST_R_NOENGINE);
-#endif
}
rsa = RSA_new();
@@ -1563,88 +1515,11 @@ static isc_result_t
opensslrsa_fromlabel(dst_key_t *key, const char *engine, const char *label,
const char *pin)
{
-#ifdef USE_ENGINE
- ENGINE *e = NULL;
- isc_result_t ret;
- EVP_PKEY *pkey = NULL;
- RSA *rsa = NULL, *pubrsa = NULL;
- char *colon, *tmpengine = NULL;
- const BIGNUM *ex = NULL;
-
- UNUSED(pin);
-
- if (engine == NULL) {
- if (strchr(label, ':') == NULL)
- DST_RET(DST_R_NOENGINE);
- tmpengine = isc_mem_strdup(key->mctx, label);
- if (tmpengine == NULL)
- DST_RET(ISC_R_NOMEMORY);
- colon = strchr(tmpengine, ':');
- INSIST(colon != NULL);
- *colon = '\0';
- }
- e = dst__openssl_getengine(engine);
- if (e == NULL)
- DST_RET(DST_R_NOENGINE);
- pkey = ENGINE_load_public_key(e, label, NULL, NULL);
- if (pkey != NULL) {
- pubrsa = EVP_PKEY_get1_RSA(pkey);
- EVP_PKEY_free(pkey);
- if (pubrsa == NULL)
- DST_RET(dst__openssl_toresult(DST_R_OPENSSLFAILURE));
- }
- pkey = ENGINE_load_private_key(e, label, NULL, NULL);
- if (pkey == NULL)
- DST_RET(dst__openssl_toresult2("ENGINE_load_private_key",
- ISC_R_NOTFOUND));
- if (tmpengine != NULL) {
- key->engine = tmpengine;
- tmpengine = NULL;
- } else {
- key->engine = isc_mem_strdup(key->mctx, engine);
- if (key->engine == NULL)
- DST_RET(ISC_R_NOMEMORY);
- }
- key->label = isc_mem_strdup(key->mctx, label);
- if (key->label == NULL)
- DST_RET(ISC_R_NOMEMORY);
- rsa = EVP_PKEY_get1_RSA(pkey);
- if (rsa == NULL)
- DST_RET(dst__openssl_toresult(DST_R_OPENSSLFAILURE));
- if (rsa_check(rsa, pubrsa) != ISC_R_SUCCESS)
- DST_RET(DST_R_INVALIDPRIVATEKEY);
- RSA_get0_key(rsa, NULL, &ex, NULL);
- if (BN_num_bits(ex) > RSA_MAX_PUBEXP_BITS)
- DST_RET(ISC_R_RANGE);
- if (pubrsa != NULL)
- RSA_free(pubrsa);
- key->key_size = EVP_PKEY_bits(pkey);
-#if USE_EVP
- key->keydata.pkey = pkey;
- RSA_free(rsa);
-#else
- key->keydata.rsa = rsa;
- EVP_PKEY_free(pkey);
-#endif
- return (ISC_R_SUCCESS);
-
- err:
- if (tmpengine != NULL)
- isc_mem_free(key->mctx, tmpengine);
- if (rsa != NULL)
- RSA_free(rsa);
- if (pubrsa != NULL)
- RSA_free(pubrsa);
- if (pkey != NULL)
- EVP_PKEY_free(pkey);
- return (ret);
-#else
UNUSED(key);
UNUSED(engine);
UNUSED(label);
UNUSED(pin);
return(DST_R_NOENGINE);
-#endif
}
static dst_func_t opensslrsa_functions = {
@@ -1695,11 +1570,4 @@ dst__opensslrsa_init(dst_func_t **funcp, unsigned char algorithm) {
return (ISC_R_SUCCESS);
}
-#else /* OPENSSL */
-
-#include <isc/util.h>
-
-EMPTY_TRANSLATION_UNIT
-
-#endif /* OPENSSL */
/*! \file */
diff --git a/usr.sbin/bind/lib/isc/task.c b/usr.sbin/bind/lib/isc/task.c
index a69b9cf245e..ce0d3023ef5 100644
--- a/usr.sbin/bind/lib/isc/task.c
+++ b/usr.sbin/bind/lib/isc/task.c
@@ -41,10 +41,6 @@
#include <isc/util.h>
#include <isc/xml.h>
-#ifdef OPENSSL_LEAKS
-#include <openssl/err.h>
-#endif
-
/*%
* For BIND9 internal applications:
* when built with threads we use multiple worker threads shared by the whole
@@ -1286,10 +1282,6 @@ run(void *uap) {
XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL,
ISC_MSG_EXITING, "exiting"));
-#ifdef OPENSSL_LEAKS
- ERR_remove_state(0);
-#endif
-
return ((isc_threadresult_t)0);
}
#endif /* USE_WORKER_THREADS */
diff --git a/usr.sbin/bind/lib/isc/timer.c b/usr.sbin/bind/lib/isc/timer.c
index 9c2eab184ef..7c50fc61de6 100644
--- a/usr.sbin/bind/lib/isc/timer.c
+++ b/usr.sbin/bind/lib/isc/timer.c
@@ -14,7 +14,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: timer.c,v 1.7 2020/01/09 13:47:14 florian Exp $ */
+/* $Id: timer.c,v 1.8 2020/01/09 14:21:27 florian Exp $ */
/*! \file */
@@ -36,10 +36,6 @@
#include <isc/timer.h>
#include <isc/util.h>
-#ifdef OPENSSL_LEAKS
-#include <openssl/err.h>
-#endif
-
/* See task.c about the following definition: */
#define USE_SHARED_MANAGER
@@ -813,10 +809,6 @@ run(void *uap) {
}
UNLOCK(&manager->lock);
-#ifdef OPENSSL_LEAKS
- ERR_remove_state(0);
-#endif
-
return ((isc_threadresult_t)0);
}
#endif /* USE_TIMER_THREAD */