Dan Fandrich patch:

1 - let libssh2 compile with OpenSSL 0.9.6b.  This is due to 'crypt' is found
in one of its header files and EVP_MAX_BLOCK_LENGTH not being found.

2 - The EXEEXT patch is because automake 1.7 doesn't support it, and recent
automakes add it automatically
This commit is contained in:
Daniel Stenberg 2007-03-14 21:59:12 +00:00
parent 689c394c57
commit 75ceed5776
3 changed files with 14 additions and 10 deletions

View File

@ -90,7 +90,7 @@ static int init (LIBSSH2_SESSION *session,
return 0;
}
static int crypt(LIBSSH2_SESSION *session, unsigned char *block, void **abstract)
static int encrypt(LIBSSH2_SESSION *session, unsigned char *block, void **abstract)
{
struct crypt_ctx *cctx = *(struct crypt_ctx **)abstract;
(void)session;
@ -117,7 +117,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_aes128_cbc = {
16, /* secret length -- 16*8 == 128bit */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_aes128
};
@ -129,7 +129,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_aes192_cbc = {
24, /* secret length -- 24*8 == 192bit */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_aes192
};
@ -141,7 +141,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_aes256_cbc = {
32, /* secret length -- 32*8 == 256bit */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_aes256
};
@ -154,7 +154,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_rijndael_cbc_lysator_liu_se = {
32, /* secret length -- 32*8 == 256bit */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_aes256
};
@ -168,7 +168,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_blowfish_cbc = {
16, /* secret length */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_blowfish
};
@ -182,7 +182,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_arcfour = {
16, /* secret length */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_arcfour
};
@ -196,7 +196,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_cast128_cbc = {
16, /* secret length */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_cast5
};
@ -210,7 +210,7 @@ static LIBSSH2_CRYPT_METHOD libssh2_crypt_method_3des_cbc = {
24, /* secret length */
0, /* flags */
&init,
&crypt,
&encrypt,
&dtor,
_libssh2_cipher_3des
};

View File

@ -39,6 +39,10 @@
#include "libssh2_priv.h"
#include <string.h>
#ifndef EVP_MAX_BLOCK_LENGTH
#define EVP_MAX_BLOCK_LENGTH 32
#endif
int _libssh2_rsa_new(libssh2_rsa_ctx **rsa,
const unsigned char *edata,
unsigned long elen,

View File

@ -2,6 +2,6 @@ AM_CPPFLAGS = -I$(top_srcdir)/include
AM_LDFLAGS = -no-install
LDADD = ../src/libssh2.la
ctests = simple$(EXEEXT)
ctests = simple
TESTS = $(ctests)
check_PROGRAMS = $(ctests)