lol

Revert "Revert "openssl: 1.1.1k -> 1.1.1l" (#135999)"

This reverts commit b2b0115e70003e0070a50a1e0217a43c7e081588.

+60 -2
+56
pkgs/development/libraries/openssl/1.1/macos-yosemite-compat.patch
··· 1 + From cef404f1e7a598166cbc2fd2e0048f7e2d752ad5 Mon Sep 17 00:00:00 2001 2 + From: David Carlier <devnexen@gmail.com> 3 + Date: Tue, 24 Aug 2021 22:40:14 +0100 4 + Subject: [PATCH] Darwin platform allows to build on releases before 5 + Yosemite/ios 8. 6 + 7 + issue #16407 #16408 8 + --- 9 + crypto/rand/rand_unix.c | 5 +---- 10 + include/crypto/rand.h | 10 ++++++++++ 11 + 2 files changed, 11 insertions(+), 4 deletions(-) 12 + 13 + diff --git a/crypto/rand/rand_unix.c b/crypto/rand/rand_unix.c 14 + index 43f1069d151d..0f4525106af7 100644 15 + --- a/crypto/rand/rand_unix.c 16 + +++ b/crypto/rand/rand_unix.c 17 + @@ -34,9 +34,6 @@ 18 + #if defined(__OpenBSD__) 19 + # include <sys/param.h> 20 + #endif 21 + -#if defined(__APPLE__) 22 + -# include <CommonCrypto/CommonRandom.h> 23 + -#endif 24 + 25 + #if defined(OPENSSL_SYS_UNIX) || defined(__DJGPP__) 26 + # include <sys/types.h> 27 + @@ -381,7 +378,7 @@ static ssize_t syscall_random(void *buf, size_t buflen) 28 + if (errno != ENOSYS) 29 + return -1; 30 + } 31 + -# elif defined(__APPLE__) 32 + +# elif defined(OPENSSL_APPLE_CRYPTO_RANDOM) 33 + if (CCRandomGenerateBytes(buf, buflen) == kCCSuccess) 34 + return (ssize_t)buflen; 35 + 36 + diff --git a/include/crypto/rand.h b/include/crypto/rand.h 37 + index 5350d3a93119..674f840fd13c 100644 38 + --- a/include/crypto/rand.h 39 + +++ b/include/crypto/rand.h 40 + @@ -20,6 +20,16 @@ 41 + 42 + # include <openssl/rand.h> 43 + 44 + +# if defined(__APPLE__) && !defined(OPENSSL_NO_APPLE_CRYPTO_RANDOM) 45 + +# include <Availability.h> 46 + +# if (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101000) || \ 47 + + (defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 80000) 48 + +# define OPENSSL_APPLE_CRYPTO_RANDOM 1 49 + +# include <CommonCrypto/CommonCryptoError.h> 50 + +# include <CommonCrypto/CommonRandom.h> 51 + +# endif 52 + +# endif 53 + + 54 + /* forward declaration */ 55 + typedef struct rand_pool_st RAND_POOL; 56 +
+4 -2
pkgs/development/libraries/openssl/default.nix
··· 192 192 }; 193 193 194 194 openssl_1_1 = common { 195 - version = "1.1.1k"; 196 - sha256 = "1rdfzcrxy9y38wqdw5942vmdax9hjhgrprzxm42csal7p5shhal9"; 195 + version = "1.1.1l"; 196 + sha256 = "sha256-C3o+XlnDSCf+DDp0t+yLrvMCuY+oAIjX+RU6oW+na9E="; 197 197 patches = [ 198 198 ./1.1/nix-ssl-cert-file.patch 199 199 200 200 (if stdenv.hostPlatform.isDarwin 201 201 then ./1.1/use-etc-ssl-certs-darwin.patch 202 202 else ./1.1/use-etc-ssl-certs.patch) 203 + ] ++ lib.optionals (stdenv.isDarwin) [ 204 + ./1.1/macos-yosemite-compat.patch 203 205 ]; 204 206 withDocs = true; 205 207 };