-
-
Save pavels/f6a8cd7e33d3d5a3125308fa6a429367 to your computer and use it in GitHub Desktop.
Openssl 3.0 oatch for ruby 2.4
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
diff -Naurp ruby-2.5.9.orig/ext/openssl/deprecation.rb ruby-2.5.9/ext/openssl/deprecation.rb | |
--- ruby-2.5.9.orig/ext/openssl/deprecation.rb 2021-04-05 04:46:35.000000000 -0700 | |
+++ ruby-2.5.9/ext/openssl/deprecation.rb 2022-08-19 12:02:59.603496778 -0700 | |
@@ -2,7 +2,7 @@ | |
module OpenSSL | |
def self.deprecated_warning_flag | |
unless flag = (@deprecated_warning_flag ||= nil) | |
- if try_compile("", flag = "-Werror=deprecated-declarations") | |
+ if false and try_compile("", flag = "-Werror=deprecated-declarations") | |
$warnflags << " #{flag}" | |
else | |
flag = "" | |
diff -Naurp ruby-2.5.9.orig/ext/openssl/ossl_pkey_rsa.c ruby-2.5.9/ext/openssl/ossl_pkey_rsa.c | |
--- ruby-2.5.9.orig/ext/openssl/ossl_pkey_rsa.c 2021-04-05 04:46:35.000000000 -0700 | |
+++ ruby-2.5.9/ext/openssl/ossl_pkey_rsa.c 2022-08-19 12:02:33.394772672 -0700 | |
@@ -939,7 +939,8 @@ Init_ossl_rsa(void) | |
rb_define_method(cRSA, "params", ossl_rsa_get_params, 0); | |
DefRSAConst(PKCS1_PADDING); | |
- DefRSAConst(SSLV23_PADDING); | |
+ // Bravenet - Disable, to allow compilation with OpenSSL 3.0+. Removed from OpenSSL 3.0+ | |
+ //DefRSAConst(SSLV23_PADDING); | |
DefRSAConst(NO_PADDING); | |
DefRSAConst(PKCS1_OAEP_PADDING); | |
diff -Naurp ruby-2.5.9.orig/ext/openssl/openssl_missing.h ruby-2.5.9/ext/openssl/openssl_missing.h | |
--- ruby-2.5.9.orig/ext/openssl/openssl_missing.h 2024-01-16 23:11:27.795800145 +0100 | |
+++ ruby-2.5.9/ext/openssl/openssl_missing.h 2024-01-16 23:12:00.516077758 +0100 | |
@@ -28,9 +28,9 @@ | |
#endif | |
/* added in 1.0.0 */ | |
-#if !defined(HAVE_EVP_PKEY_BASE_ID) | |
-# define EVP_PKEY_base_id(pkey) EVP_PKEY_type((pkey)->type) | |
-#endif | |
+//#if !defined(HAVE_EVP_PKEY_BASE_ID) | |
+//# define EVP_PKEY_base_id(pkey) EVP_PKEY_type((pkey)->type) | |
+//#endif | |
#if !defined(HAVE_EVP_CIPHER_CTX_COPY) | |
int ossl_EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *, const EVP_CIPHER_CTX *); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment