summaryrefslogtreecommitdiff
path: root/radsecproxy.h
diff options
context:
space:
mode:
authorvenaas <venaas>2007-01-04 13:33:27 +0000
committervenaas <venaas@e88ac4ed-0b26-0410-9574-a7f39faa03bf>2007-01-04 13:33:27 +0000
commitb1352f95528e36234066ce4fecbebf3b88f008d0 (patch)
tree6556511ec5f2629e0586c257a23453b65536d24c /radsecproxy.h
parentce0a23254cf4d1648b69d870dad1c6ea5b239cb7 (diff)
changed from struct peer to struct server and struct client
git-svn-id: https://svn.testnett.uninett.no/radsecproxy/trunk@23 e88ac4ed-0b26-0410-9574-a7f39faa03bf
Diffstat (limited to 'radsecproxy.h')
-rw-r--r--radsecproxy.h31
1 files changed, 19 insertions, 12 deletions
diff --git a/radsecproxy.h b/radsecproxy.h
index 77d02ae..7ce9a50 100644
--- a/radsecproxy.h
+++ b/radsecproxy.h
@@ -41,7 +41,7 @@ struct request {
uint8_t tries;
uint8_t received;
struct timeval timeout;
- struct peer *from;
+ struct client *from;
uint8_t origid; /* used by servwr */
char origauth[16]; /* used by servwr */
struct sockaddr_storage fromsa; /* used by udpservwr */
@@ -61,30 +61,37 @@ struct replyq {
pthread_cond_t count_cond;
};
-struct peer {
+struct client {
char type; /* U for UDP, T for TLS */
char *host;
char *port;
+ char *secret;
+ SSL *ssl;
+ struct addrinfo *addrinfo;
+ struct replyq *replyq;
+ int replycount;
+ pthread_mutex_t replycount_mutex;
+ pthread_cond_t replycount_cond;
+};
+
+struct server {
+ char type; /* U for UDP, T for TLS */
+ char *host;
+ char *port;
+ char *secret;
+ SSL *ssl;
+ struct addrinfo *addrinfo;
char *realmdata;
char **realms;
- char *secret;
- SSL *sslcl, *sslsrv;
+ int sock;
pthread_mutex_t lock;
pthread_t clientth;
- int sockcl;
- struct addrinfo *addrinfo;
struct timeval lastconnecttry;
uint8_t connectionok;
- /* requests and newrq* are requests passed from servers to clients */
struct request *requests;
uint8_t newrq;
pthread_mutex_t newrq_mutex;
pthread_cond_t newrq_cond;
- /* repl* are replies passed from clients to tls servers */
- struct replyq *replyq;
- int replycount;
- pthread_mutex_t replycount_mutex;
- pthread_cond_t replycount_cond;
};
void errx(char *format, ...);