00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef WRAPPER_H_
00023 #define WRAPPER_H_
00024
00025 #include "config.h"
00026 #include "libssh/libcrypto.h"
00027 #include "libssh/libgcrypt.h"
00028
00029 MD5CTX md5_init(void);
00030 void md5_update(MD5CTX c, const void *data, unsigned long len);
00031 void md5_final(unsigned char *md,MD5CTX c);
00032 SHACTX sha1_init(void);
00033 void sha1_update(SHACTX c, const void *data, unsigned long len);
00034 void sha1_final(unsigned char *md,SHACTX c);
00035 void sha1(unsigned char *digest,int len,unsigned char *hash);
00036 #define HMAC_SHA1 1
00037 #define HMAC_MD5 2
00038 HMACCTX hmac_init(const void *key,int len,int type);
00039 void hmac_update(HMACCTX c, const void *data, unsigned long len);
00040 void hmac_final(HMACCTX ctx,unsigned char *hashmacbuf,unsigned int *len);
00041
00042 int crypt_set_algorithms(ssh_session );
00043 int crypt_set_algorithms_server(ssh_session session);
00044 struct ssh_crypto_struct *crypto_new(void);
00045 void crypto_free(struct ssh_crypto_struct *crypto);
00046
00047 void ssh_reseed(void);
00048
00049 #endif