This repository has been archived by the owner on May 20, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 252
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
upgpkg: transmission 3.00-6: fix compatibility with OpenSSL 3.0
Apply patch from Gentoo that enables the legacy provider (FS#76411). git-svn-id: file:///srv/repos/svn-packages/svn@460534 eb2447ed-0c53-47e4-bac8-5bc4a241df78
- Loading branch information
foutrelis
authored and
svntogit
committed
Nov 3, 2022
1 parent
58dbb8a
commit 936dc93
Showing
2 changed files
with
45 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
From 6ee128b95bacaff20746538dc97c2b8e2b9fcc29 Mon Sep 17 00:00:00 2001 | ||
From: Mike Gilbert <floppym@gentoo.org> | ||
Date: Sun, 15 May 2022 10:54:38 -0400 | ||
Subject: [PATCH] openssl: load "legacy" provider for RC4 | ||
|
||
--- | ||
libtransmission/crypto-utils-openssl.c | 7 +++++++ | ||
1 file changed, 7 insertions(+) | ||
|
||
diff --git a/libtransmission/crypto-utils-openssl.c b/libtransmission/crypto-utils-openssl.c | ||
index 45fd71913..14d680654 100644 | ||
--- a/libtransmission/crypto-utils-openssl.c | ||
+++ b/libtransmission/crypto-utils-openssl.c | ||
@@ -20,6 +20,9 @@ | ||
#include <openssl/rand.h> | ||
#include <openssl/ssl.h> | ||
#include <openssl/x509.h> | ||
+#if OPENSSL_VERSION_MAJOR >= 3 | ||
+#include <openssl/provider.h> | ||
+#endif | ||
|
||
#include "transmission.h" | ||
#include "crypto-utils.h" | ||
@@ -184,6 +187,10 @@ static void openssl_evp_cipher_context_free(EVP_CIPHER_CTX* handle) | ||
|
||
tr_rc4_ctx_t tr_rc4_new(void) | ||
{ | ||
+#if OPENSSL_VERSION_MAJOR >= 3 | ||
+ OSSL_PROVIDER_load(NULL, "default"); | ||
+ OSSL_PROVIDER_load(NULL, "legacy"); | ||
+#endif | ||
EVP_CIPHER_CTX* handle = EVP_CIPHER_CTX_new(); | ||
|
||
if (check_result(EVP_CipherInit_ex(handle, EVP_rc4(), NULL, NULL, NULL, -1))) | ||
-- | ||
2.35.1 | ||
|