From c48e3bc42f0b62953391dc8eacf47f719b6a5ab9 Mon Sep 17 00:00:00 2001 From: Eric Hameleers Date: Wed, 25 Feb 2015 20:34:32 +0100 Subject: libssh: re-added as a dependency for kde-rumtime. The version of libssh in Slackware is too old, and the 'sftp' kioslave (kio_sftp.so) will refuse to compile. --- deps/libssh/libssh_libgcrypt.patch | 51 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 deps/libssh/libssh_libgcrypt.patch (limited to 'deps/libssh/libssh_libgcrypt.patch') diff --git a/deps/libssh/libssh_libgcrypt.patch b/deps/libssh/libssh_libgcrypt.patch new file mode 100644 index 0000000..622c338 --- /dev/null +++ b/deps/libssh/libssh_libgcrypt.patch @@ -0,0 +1,51 @@ +From 3880a8ed80a4b1e2c052bd62f328bba2f869d5ae Mon Sep 17 00:00:00 2001 +From: Aris Adamantiadis +Date: Mon, 29 Dec 2014 15:06:33 +0000 +Subject: Fix the dh.c build with libgcrypt + +Fixes bug reported by gentoo at https://bugs.gentoo.org/show_bug.cgi?id=533424 +The function was only used by EDCSA backend which are not supported by the libgcrypt code anyway. +--- +diff --git a/include/libssh/dh.h b/include/libssh/dh.h +index f28b916..89872e3 100644 +--- a/include/libssh/dh.h ++++ b/include/libssh/dh.h +@@ -49,7 +49,9 @@ int hashbufin_add_cookie(ssh_session session, unsigned char *cookie); + int hashbufout_add_cookie(ssh_session session); + int generate_session_keys(ssh_session session); + bignum make_string_bn(ssh_string string); ++#ifdef HAVE_LIBCRYPTO + void make_string_bn_inplace(ssh_string string, bignum bnout); ++#endif /* HAVE_LIBCRYPTO */ + ssh_string make_bignum_string(bignum num); + + #endif /* DH_H_ */ +diff --git a/src/dh.c b/src/dh.c +index 84355d4..010a1dd 100644 +--- a/src/dh.c ++++ b/src/dh.c +@@ -407,14 +407,17 @@ bignum make_string_bn(ssh_string string){ + return bn; + } + ++#ifdef HAVE_LIBCRYPTO ++/** @internal ++ * @brief converts the content of a SSH string in an already allocated bignum ++ * @warning only available with OpenSSL builds ++ */ + void make_string_bn_inplace(ssh_string string, bignum bnout) { + unsigned int len = ssh_string_len(string); +-#ifdef HAVE_LIBGCRYPT +- #error "unsupported" +-#elif defined HAVE_LIBCRYPTO + bignum_bin2bn(string->data, len, bnout); +-#endif + } ++#endif /* HAVE_LIBCRYPTO */ ++ + + ssh_string dh_get_e(ssh_session session) { + return make_bignum_string(session->next_crypto->e); +-- +cgit v0.9.1 + -- cgit v1.2.3