From e436c963f0976b885a7db04681344779e26dd3b5 Mon Sep 17 00:00:00 2001 From: Arne Schwabe Date: Wed, 23 Apr 2014 09:56:37 +0200 Subject: Update OpenSSL to 1.0.1g and statically link OpenVPN with it --- main/openssl/crypto/rc2/rc2.h | 4 +++- main/openssl/crypto/rc2/rc2_skey.c | 8 ++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) (limited to 'main/openssl/crypto/rc2') diff --git a/main/openssl/crypto/rc2/rc2.h b/main/openssl/crypto/rc2/rc2.h index 34c83623..e542ec94 100644 --- a/main/openssl/crypto/rc2/rc2.h +++ b/main/openssl/crypto/rc2/rc2.h @@ -79,7 +79,9 @@ typedef struct rc2_key_st RC2_INT data[64]; } RC2_KEY; - +#ifdef OPENSSL_FIPS +void private_RC2_set_key(RC2_KEY *key, int len, const unsigned char *data,int bits); +#endif void RC2_set_key(RC2_KEY *key, int len, const unsigned char *data,int bits); void RC2_ecb_encrypt(const unsigned char *in,unsigned char *out,RC2_KEY *key, int enc); diff --git a/main/openssl/crypto/rc2/rc2_skey.c b/main/openssl/crypto/rc2/rc2_skey.c index 0150b0e0..6668ac01 100644 --- a/main/openssl/crypto/rc2/rc2_skey.c +++ b/main/openssl/crypto/rc2/rc2_skey.c @@ -56,6 +56,7 @@ * [including the GNU Public Licence.] */ +#include #include #include "rc2_locl.h" @@ -95,6 +96,13 @@ static const unsigned char key_table[256]={ * the same as specifying 1024 for the 'bits' parameter. Bsafe uses * a version where the bits parameter is the same as len*8 */ void RC2_set_key(RC2_KEY *key, int len, const unsigned char *data, int bits) +#ifdef OPENSSL_FIPS + { + fips_cipher_abort(RC2); + private_RC2_set_key(key, len, data, bits); + } +void private_RC2_set_key(RC2_KEY *key, int len, const unsigned char *data, int bits) +#endif { int i,j; unsigned char *k; -- cgit v1.2.3