packages/net/vpnc/patches/110-openssl-deprecated.patch
Ilya Lipnitskiy 9cbd369aa9
vpnc: update to maintained github fork
The SVN-based version has not changed in years. Many distros use this
fork as evident here: https://github.com/streambinder/vpnc/issues/14

Compile tested against GnuTLS and OpenSSL on ramips target.

Fixes #14119.

Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
2021-02-08 20:55:34 -08:00

23 lines
563 B
Diff

--- a/src/crypto-openssl.c
+++ b/src/crypto-openssl.c
@@ -20,6 +20,7 @@
#include <string.h>
#include <errno.h>
#include <openssl/pem.h>
+#include <openssl/rsa.h>
#include "config.h"
#include "sysdep.h"
#include "crypto.h"
@@ -35,10 +36,12 @@ crypto_ctx *crypto_ctx_new(crypto_error **error)
return NULL;
}
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
OpenSSL_add_all_ciphers();
OpenSSL_add_all_digests();
OpenSSL_add_all_algorithms();
ERR_load_crypto_strings();
+#endif
memset(ctx, 0, sizeof(crypto_ctx));
ctx->stack = sk_X509_new_null();