projects
/
tinc
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Moving files, first attempt at gcrypt compatibility, more interface
[tinc]
/
lib
/
node.h
diff --git
a/src/node.h
b/lib/node.h
similarity index 90%
rename from
src/node.h
rename to
lib/node.h
index
0b61544
..
b43c2b4
100644
(file)
--- a/
src/node.h
+++ b/
lib/node.h
@@
-17,12
+17,14
@@
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- $Id: node.h,v 1.
2 2002/04/09 15:26:00
zarq Exp $
+ $Id: node.h,v 1.
1 2002/04/28 12:46:26
zarq Exp $
*/
#ifndef __TINC_NODE_H__
#define __TINC_NODE_H__
*/
#ifndef __TINC_NODE_H__
#define __TINC_NODE_H__
+#include <gcrypt.h>
+
#include <avl_tree.h>
#include "subnet.h"
#include <avl_tree.h>
#include "subnet.h"
@@
-47,11
+49,23
@@
typedef struct node_t {
struct node_status_t status;
struct node_status_t status;
- const EVP_CIPHER *cipher; /* Cipher type for UDP packets */
+#ifdef USE_OPENSSL
+ const EVP_CIPHER *cipher; /* Cipher type for UDP packets */
+#endif
+#ifdef USE_GCRYPT
+ GCRY_CIPHER_HD cipher; /* Cipher type for UDP packets */
+#endif
+
char *key; /* Cipher key and iv */
int keylength; /* Cipher key and iv length*/
char *key; /* Cipher key and iv */
int keylength; /* Cipher key and iv length*/
+#ifdef USE_OPENSSL
const EVP_MD *digest; /* Digest type for MAC */
const EVP_MD *digest; /* Digest type for MAC */
+#endif
+#ifdef USE_GCRYPT
+ GCRY_MD_HD digest; /* Digest type for MAC */
+#endif
+
int maclength; /* Length of MAC */
int compression; /* Compressionlevel, 0 = no compression */
int maclength; /* Length of MAC */
int compression; /* Compressionlevel, 0 = no compression */
@@
-69,6
+83,8
@@
typedef struct node_t {
unsigned int sent_seqno; /* Sequence number last sent to this node */
unsigned int received_seqno; /* Sequence number last received from this node */
unsigned int sent_seqno; /* Sequence number last sent to this node */
unsigned int received_seqno; /* Sequence number last received from this node */
+
+ void *data; /* Interface details */
} node_t;
extern struct node_t *myself;
} node_t;
extern struct node_t *myself;