From: gthess Date: Tue, 1 Feb 2022 16:54:42 +0000 (+0100) Subject: Prefer the libressl API from when it was available X-Git-Tag: release-1.15.0rc1~15^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F603%2Fhead;p=thirdparty%2Funbound.git Prefer the libressl API from when it was available --- diff --git a/sldns/keyraw.c b/sldns/keyraw.c index a40f1e860..befe1f722 100644 --- a/sldns/keyraw.c +++ b/sldns/keyraw.c @@ -250,7 +250,8 @@ sldns_key_buf2dsa_raw(unsigned char* key, size_t len) if(!(dsa = DSA_new())) { return NULL; } -#if OPENSSL_VERSION_NUMBER < 0x10100000 +#if OPENSSL_VERSION_NUMBER < 0x10100000 || \ + (defined(HAVE_LIBRESSL) && LIBRESSL_VERSION_NUMBER < 0x02070000f) #ifndef S_SPLINT_S dsa->p = P; dsa->q = Q; @@ -428,7 +429,8 @@ sldns_key_buf2rsa_raw(unsigned char* key, size_t len) BN_free(modulus); return NULL; } -#if OPENSSL_VERSION_NUMBER < 0x10100000 +#if OPENSSL_VERSION_NUMBER < 0x10100000 || \ + (defined(HAVE_LIBRESSL) && LIBRESSL_VERSION_NUMBER < 0x02070000f) #ifndef S_SPLINT_S rsa->n = modulus; rsa->e = exponent;