Ssl correction.

This commit is contained in:
Jon Ciesla 2010-06-01 19:03:50 +00:00
parent eb59c7cc32
commit d1fa04c4eb
2 changed files with 27 additions and 14 deletions

View File

@ -1,14 +1,24 @@
diff -up bacula-3.0.2/bacula-3.0.2/src/lib/crypto.c.openssl bacula-3.0.2/bacula-3.0.2/src/lib/crypto.c
--- bacula-3.0.2/bacula-3.0.2/src/lib/crypto.c.openssl 2008-11-06 20:10:08.000000000 +0100
+++ bacula-3.0.2/bacula-3.0.2/src/lib/crypto.c 2009-08-22 12:48:20.000000000 +0200
@@ -973,6 +977,10 @@ void crypto_sign_free(SIGNATURE *sig)
free (sig);
}
diff -up bacula-5.0.2/bacula-5.0.2/src/lib/crypto.c.openssl bacula-5.0.2/bacula-5.0.2/src/lib/crypto.c
--- bacula-5.0.2/bacula-5.0.2/src/lib/crypto.c.openssl 2010-04-27 21:58:29.000000000 +0200
+++ bacula-5.0.2/bacula-5.0.2/src/lib/crypto.c 2010-06-01 17:51:52.846894465 +0200
@@ -51,7 +51,7 @@
* For OpenSSL version 1.x, EVP_PKEY_encrypt no longer
* exists. It was not an official API.
*/
-#ifdef HAVE_OPENSSLv1
+#ifdef OPENSSL_VERSION_NUMBER >= 0x10000000L
#define EVP_PKEY_encrypt EVP_PKEY_encrypt_old
#define EVP_PKEY_decrypt EVP_PKEY_decrypt_old
#endif
diff -up bacula-5.0.2/bacula-5.0.2/src/lib/tls.c.openssl bacula-5.0.2/bacula-5.0.2/src/lib/tls.c
--- bacula-5.0.2/bacula-5.0.2/src/lib/tls.c.openssl 2010-04-27 21:58:29.000000000 +0200
+++ bacula-5.0.2/bacula-5.0.2/src/lib/tls.c 2010-06-01 17:52:15.535769446 +0200
@@ -315,7 +315,7 @@ bool tls_postconnect_verify_host(JCR *jc
extname = OBJ_nid2sn(OBJ_obj2nid(X509_EXTENSION_get_object(ext)));
+#if OPENSSL_VERSION_NUMBER >= 0x10000000L
+#define EVP_PKEY_decrypt EVP_PKEY_decrypt_old
+#define EVP_PKEY_encrypt EVP_PKEY_encrypt_old
+#endif
/*
* Create a new encryption session.
* Returns: A pointer to a CRYPTO_SESSION object on success.
if (strcmp(extname, "subjectAltName") == 0) {
-#ifdef HAVE_OPENSSLv1
+#ifdef OPENSSL_VERSION_NUMBER >= 0x10000000L
const X509V3_EXT_METHOD *method;
#else
X509V3_EXT_METHOD *method;

View File

@ -8,7 +8,7 @@
Summary: Cross platform network backup for Linux, Unix, Mac and Windows
Name: bacula
Version: 5.0.2
Release: 2%{?dist}
Release: 3%{?dist}
# See LICENSE for details
License: GPLv2 with exceptions
Group: System Environment/Daemons
@ -1021,6 +1021,9 @@ fi
%changelog
* Tue Jun 01 2010 Jon Ciesla <limb@jcomserv.net - 5.0.2-3
- Corrected ssl patch, court. jgorig.
* Wed May 19 2010 Jon Ciesla <limb@jcomserv.net - 5.0.2-2
- Corrected bat build, BZ 593149.
- Corrected ssl patch.