From: "Pacho Ramos" <pacho@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-irc/epic5/, net-irc/epic5/files/
Date: Sat, 26 Jan 2019 16:36:31 +0000 (UTC) [thread overview]
Message-ID: <1548520580.c76d64f8cf1e2ea30b50ee3d3aa9f3d895c9b5ca.pacho@gentoo> (raw)
commit: c76d64f8cf1e2ea30b50ee3d3aa9f3d895c9b5ca
Author: Pacho Ramos <pacho <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 26 16:36:02 2019 +0000
Commit: Pacho Ramos <pacho <AT> gentoo <DOT> org>
CommitDate: Sat Jan 26 16:36:20 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c76d64f8
net-irc/epic5: Debian patch for openssl-1.1
Closes: https://bugs.gentoo.org/676286
Package-Manager: Portage-2.3.58, Repoman-2.3.12
Signed-off-by: Pacho Ramos <pacho <AT> gentoo.org>
net-irc/epic5/epic5-2.0.1.ebuild | 5 ++
net-irc/epic5/files/epic5-2.0.1-openssl-1.1.patch | 77 +++++++++++++++++++++++
2 files changed, 82 insertions(+)
diff --git a/net-irc/epic5/epic5-2.0.1.ebuild b/net-irc/epic5/epic5-2.0.1.ebuild
index ac3c4b0060a..e5ebd880946 100644
--- a/net-irc/epic5/epic5-2.0.1.ebuild
+++ b/net-irc/epic5/epic5-2.0.1.ebuild
@@ -33,6 +33,11 @@ DEPEND="${RDEPEND}
S="${WORKDIR}/${P}"
+PATCHES=(
+ # From Debian
+ "${FILESDIR}/${P}-openssl-1.1.patch"
+)
+
src_configure() {
# Because of our REQUIRED_USE constraints above, we know that
# ruby_get_use_implementations will only ever return one ruby
diff --git a/net-irc/epic5/files/epic5-2.0.1-openssl-1.1.patch b/net-irc/epic5/files/epic5-2.0.1-openssl-1.1.patch
new file mode 100644
index 00000000000..254035e6d38
--- /dev/null
+++ b/net-irc/epic5/files/epic5-2.0.1-openssl-1.1.patch
@@ -0,0 +1,77 @@
+Index: epic5-2.0/source/crypto.c
+===================================================================
+--- epic5-2.0.orig/source/crypto.c
++++ epic5-2.0/source/crypto.c
+@@ -282,9 +282,9 @@ static char * decipher_evp (const unsign
+ unsigned char *iv = NULL;
+ unsigned long errcode;
+ int outlen2;
+- EVP_CIPHER_CTX a;
+- EVP_CIPHER_CTX_init(&a);
+- EVP_CIPHER_CTX_set_padding(&a, 0);
++ EVP_CIPHER_CTX *a = EVP_CIPHER_CTX_new();
++ EVP_CIPHER_CTX_init(a);
++ EVP_CIPHER_CTX_set_padding(a, 0);
+
+ if (ivsize > 0)
+ iv = new_malloc(ivsize);
+@@ -292,18 +292,19 @@ static char * decipher_evp (const unsign
+ if (ivsize > 0)
+ memcpy(iv, ciphertext, ivsize);
+
+- EVP_DecryptInit_ex(&a, type, NULL, NULL, iv);
+- EVP_CIPHER_CTX_set_key_length(&a, passwdlen);
+- EVP_CIPHER_CTX_set_padding(&a, 0);
+- EVP_DecryptInit_ex(&a, NULL, NULL, passwd, NULL);
++ EVP_DecryptInit_ex(a, type, NULL, NULL, iv);
++ EVP_CIPHER_CTX_set_key_length(a, passwdlen);
++ EVP_CIPHER_CTX_set_padding(a, 0);
++ EVP_DecryptInit_ex(a, NULL, NULL, passwd, NULL);
+
+- if (EVP_DecryptUpdate(&a, outbuf, outlen, ciphertext, cipherlen) != 1)
++ if (EVP_DecryptUpdate(a, outbuf, outlen, ciphertext, cipherlen) != 1)
+ yell("EVP_DecryptUpdate died.");
+- if (EVP_DecryptFinal_ex(&a, outbuf + (*outlen), &outlen2) != 1)
++ if (EVP_DecryptFinal_ex(a, outbuf + (*outlen), &outlen2) != 1)
+ yell("EVP_DecryptFinal_Ex died.");
+ *outlen += outlen2;
+
+- EVP_CIPHER_CTX_cleanup(&a);
++ EVP_CIPHER_CTX_cleanup(a);
++ EVP_CIPHER_CTX_free(a);
+
+ ERR_load_crypto_strings();
+ while ((errcode = ERR_get_error()))
+@@ -454,9 +455,9 @@ static char * cipher_evp (const unsigned
+ unsigned long errcode;
+ u_32int_t randomval;
+ int iv_count;
+- EVP_CIPHER_CTX a;
+- EVP_CIPHER_CTX_init(&a);
+- EVP_CIPHER_CTX_set_padding(&a, 0);
++ EVP_CIPHER_CTX *a = EVP_CIPHER_CTX_new();
++ EVP_CIPHER_CTX_init(a);
++ EVP_CIPHER_CTX_set_padding(a, 0);
+
+ if (ivsize < 0)
+ ivsize = 0; /* Shenanigans! */
+@@ -480,12 +481,13 @@ static char * cipher_evp (const unsigned
+ if (iv)
+ memcpy(outbuf, iv, ivsize);
+
+- EVP_EncryptInit_ex(&a, type, NULL, NULL, iv);
+- EVP_CIPHER_CTX_set_key_length(&a, passwdlen);
+- EVP_EncryptInit_ex(&a, NULL, NULL, passwd, NULL);
+- EVP_EncryptUpdate(&a, outbuf + ivsize, &outlen, plaintext, plaintextlen);
+- EVP_EncryptFinal_ex(&a, outbuf + ivsize + outlen, &extralen);
+- EVP_CIPHER_CTX_cleanup(&a);
++ EVP_EncryptInit_ex(a, type, NULL, NULL, iv);
++ EVP_CIPHER_CTX_set_key_length(a, passwdlen);
++ EVP_EncryptInit_ex(a, NULL, NULL, passwd, NULL);
++ EVP_EncryptUpdate(a, outbuf + ivsize, &outlen, plaintext, plaintextlen);
++ EVP_EncryptFinal_ex(a, outbuf + ivsize + outlen, &extralen);
++ EVP_CIPHER_CTX_cleanup(a);
++ EVP_CIPHER_CTX_free(a);
+ outlen += extralen;
+
+ ERR_load_crypto_strings();
next reply other threads:[~2019-01-26 16:36 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-26 16:36 Pacho Ramos [this message]
-- strict thread matches above, loose matches on Subject: below --
2018-04-20 20:01 [gentoo-commits] repo/gentoo:master commit in: net-irc/epic5/, net-irc/epic5/files/ David Seifert
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1548520580.c76d64f8cf1e2ea30b50ee3d3aa9f3d895c9b5ca.pacho@gentoo \
--to=pacho@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox