5773038 [rkeene@sledge /home/rkeene/projects/libssh-win32/v0.11/src/libssh-0.11/include/libssh]$ cat -n crypto.h
 1 /*
 2 Copyright 2003 Aris Adamantiadis
 3 
 4 This file is part of the SSH Library
 5 
 6 The SSH Library is free software; you can redistribute it and/or modify
 7 it under the terms of the GNU Lesser General Public License as published by
 8 the Free Software Foundation; either version 2.1 of the License, or (at your
 9 option) any later version.
10 
11 The SSH Library is distributed in the hope that it will be useful, but
12 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13 or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
14 License for more details.
15 
16 You should have received a copy of the GNU Lesser General Public License
17 along with the SSH Library; see the file COPYING.  If not, write to
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
19 MA 02111-1307, USA. */
20 
21 /* Crypto.h is an include file for internal structures of libssh */
22 /* It hasn't to be into the final development set of files (and btw the filename would cause problems on most systems)
	*/
23 /* Openssl has (really) stupid defines */
24 #ifdef set_key
25 #undef set_key
26 #endif
27 #ifdef cbc_encrypt
28 #undef cbc_encrypt
29 #endif
30 #ifdef cbc_decrypt
31 #undef cbc_decrypt
32 #endif
33 #ifdef des_set_key
34 #undef des_set_key
35 #endif
36 struct crypto_struct {
37     char *name; /* ssh name of the algorithm */
38     unsigned int blocksize; /* blocksize of the algo */
39     unsigned int keylen; /* length of the key structure */
40     void *key; /* a key buffer allocated for the algo */
41     unsigned int keysize; /* bytes of key used. != keylen */
42     void (*set_encrypt_key)(struct crypto_struct *cipher, void *key); /* sets the new key for immediate use */
43     void (*set_decrypt_key)(struct crypto_struct *cipher, void *key);
44     void (*cbc_encrypt)(struct crypto_struct *cipher, void *in, void *out,unsigned long len,void *IV);
45     void (*cbc_decrypt)(struct crypto_struct *cipher, void *in, void *out,unsigned long len,void *IV);
46 };
5773039 [rkeene@sledge /home/rkeene/projects/libssh-win32/v0.11/src/libssh-0.11/include/libssh]$

Click here to go back to the directory listing.
Click here to download this file.
last modified: 2005-03-04 19:54:59