mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
libssh: Fix compile without OpenSSL deprecated APIs
Backported several patches from version 0.8 to fix this. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
committed by
Kevin Darbyshire-Bryant
parent
52575dbc10
commit
7bc5aba1df
@@ -0,0 +1,29 @@
|
||||
From ab67e42d6a0529f5fb81ee86049bf10abe99f839 Mon Sep 17 00:00:00 2001
|
||||
From: Jakub Jelen <jjelen@redhat.com>
|
||||
Date: Tue, 7 Nov 2017 09:38:40 +0100
|
||||
Subject: [PATCH] pki_crypto: Avoid segfault with OpenSSL 1.1.0
|
||||
|
||||
Signed-off-by: Jakub Jelen <jjelen@redhat.com>
|
||||
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
|
||||
---
|
||||
src/pki_crypto.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/src/pki_crypto.c b/src/pki_crypto.c
|
||||
index 34d6e81c..30f49a81 100644
|
||||
--- a/src/pki_crypto.c
|
||||
+++ b/src/pki_crypto.c
|
||||
@@ -452,6 +452,10 @@ int pki_key_generate_rsa(ssh_key key, int parameter){
|
||||
int pki_key_generate_dss(ssh_key key, int parameter){
|
||||
int rc;
|
||||
#if OPENSSL_VERSION_NUMBER > 0x10100000L
|
||||
+ key->dsa = DSA_new();
|
||||
+ if (!key->dsa) {
|
||||
+ return SSH_ERROR;
|
||||
+ }
|
||||
rc = DSA_generate_parameters_ex(key->dsa,
|
||||
parameter,
|
||||
NULL, /* seed */
|
||||
--
|
||||
2.19.1
|
||||
|
||||
Reference in New Issue
Block a user