Annotation of embedaddon/mpd/src/radsrv.h, revision 1.1
1.1 ! misho 1:
! 2: /*
! 3: * radsrv.h
! 4: *
! 5: * Written by Alexander Motin <mav@FreeBSD.org>
! 6: */
! 7:
! 8: #ifndef _RADSRV_H_
! 9: #define _RADSRV_H_
! 10:
! 11: #include "defs.h"
! 12: #include <radlib.h>
! 13:
! 14: /*
! 15: * DEFINITIONS
! 16: */
! 17:
! 18: #define RADSRV_MAX_SERVERS 10
! 19:
! 20: /* Configuration options */
! 21: enum {
! 22: RADSRV_DISCONNECT, /* enable Disconnect-Request */
! 23: RADSRV_COA /* enable CoA-Request */
! 24: };
! 25:
! 26: /* Configuration for a radius server */
! 27: struct radiusclient_conf {
! 28: char *hostname;
! 29: char *sharedsecret;
! 30: struct radiusclient_conf *next;
! 31: };
! 32:
! 33: struct radsrv {
! 34: struct optinfo options;
! 35: struct u_addr addr;
! 36: in_port_t port;
! 37: int fd;
! 38: struct rad_handle *handle;
! 39: struct radiusclient_conf *clients;
! 40: EventRef event; /* connect-event */
! 41: };
! 42:
! 43: typedef struct radsrv *Radsrv;
! 44:
! 45: /*
! 46: * VARIABLES
! 47: */
! 48:
! 49: extern const struct cmdtab RadsrvSetCmds[];
! 50:
! 51: /*
! 52: * FUNCTIONS
! 53: */
! 54:
! 55: extern int RadsrvInit(Radsrv c);
! 56: extern int RadsrvOpen(Radsrv c);
! 57: extern int RadsrvClose(Radsrv c);
! 58: extern int RadsrvStat(Context ctx, int ac, char *av[], void *arg);
! 59:
! 60: #endif
! 61:
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>