diff options
author | Dmitry Kozlov <xeb@mail.ru> | 2010-09-06 22:43:20 +0400 |
---|---|---|
committer | Dmitry Kozlov <xeb@mail.ru> | 2010-09-06 22:43:20 +0400 |
commit | ec759f72fcf7d517fdfe8d043c75d0218363bc78 (patch) | |
tree | 0696c9977599bf0f20e016e5464e59a6c3fe980e /accel-pptpd/radius/radius.h | |
parent | 45243dd2f2be49cd91be1dc28932e6c9040db6a1 (diff) | |
download | accel-ppp-ec759f72fcf7d517fdfe8d043c75d0218363bc78.tar.gz accel-ppp-ec759f72fcf7d517fdfe8d043c75d0218363bc78.zip |
now compiles
Diffstat (limited to 'accel-pptpd/radius/radius.h')
-rw-r--r-- | accel-pptpd/radius/radius.h | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/accel-pptpd/radius/radius.h b/accel-pptpd/radius/radius.h index 3fe78621..109981a6 100644 --- a/accel-pptpd/radius/radius.h +++ b/accel-pptpd/radius/radius.h @@ -3,6 +3,7 @@ #include <netinet/in.h> #include "triton.h" +#include "ppp.h" #define REQ_LENGTH_MAX 4096 @@ -54,12 +55,14 @@ struct rad_req_attr_t struct rad_dict_attr_t *attr; //struct rad_dict_value_t *val; rad_value_t val; + int len; }; struct rad_packet_t { int code; int id; + int len; struct list_head attrs; void *buf; }; @@ -68,23 +71,29 @@ struct rad_req_t struct triton_md_handler_t hnd; struct triton_timer_t timeout; struct rad_packet_t pack; - struct rad_packet_t *answer; - const char *server_host; + struct rad_packet_t *reply; + const char *server_name; int server_port; struct radius_pd_t *rpd; }; +extern int conf_max_try; +extern int conf_timeout; +extern char *conf_nas_identifier; +extern char *conf_nas_ip_address; + int rad_dict_load(const char *fname); void rad_dict_free(struct rad_dict_t *dict); struct rad_dict_attr_t *rad_dict_find_attr(const char *name); struct rad_dict_attr_t *rad_dict_find_attr_type(int type); struct rad_dict_value_t *rad_dict_find_val(struct rad_dict_attr_t *, const char *name); -struct rad_req_t *rad_rec_alloc(struct radius_pd_t *rpd, int code); -void rad_rec_free(struct rad_req_t *); +struct rad_req_t *rad_req_alloc(struct radius_pd_t *rpd, int code, const char *username); +void rad_req_free(struct rad_req_t *); int rad_req_send(struct rad_req_t *); +int rad_req_wait(struct rad_req_t *, int); int rad_req_add_int(struct rad_req_t *req, const char *name, int val); int rad_req_add_val(struct rad_req_t *req, const char *name, const char *val, int len); int rad_req_add_str(struct rad_req_t *req, const char *name, const char *val, int len); |