home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.ee.lbl.gov
/
2014.05.ftp.ee.lbl.gov.tar
/
ftp.ee.lbl.gov
/
acld-1.11.tar.gz
/
acld-1.11.tar
/
acld-1.11
/
cf.h
< prev
next >
Wrap
C/C++ Source or Header
|
2012-02-07
|
3KB
|
91 lines
/* @(#) $Id: cf.h 806 2012-02-08 03:40:06Z leres $ (LBL) */
#ifndef acld_cf_h
#define acld_cf_h
#include "acl.h"
/* Validate unsigned 16 bit value */
#define VALID_PORT(p) ((p) > 0 && (p) <= 0xFFFF)
struct cf {
time_t c_time; /* unix timestamp of config file */
int c_port; /* local port to listen for clients */
int c_portro; /* read only clients */
int c_portweb; /* web registration clients */
int c_login_secs; /* seconds to between login attempts */
int c_ayt_secs; /* seconds to wait before sync'ing */
int c_sync_secs; /* seconds to wait before sync'ing */
int c_select_secs; /* default seconds in select loop */
int c_incrseq; /* increment or decrement seq numbers */
int c_netsfac; /* syslog() facility for nets_log() */
int c_lowseq; /* lowest sequence number */
int c_highseq; /* highest sequence number */
int c_maxseq; /* maximum total number of rules */
int c_lowportseq; /* lowest port sequence number */
int c_highportseq; /* highest port sequence number */
int c_lowpermithostportseq; /* lowest host/port sequence number */
int c_highpermithostportseq; /* highest host/port sequence number */
int c_nullzeromax; /* maximum total number of nullzero's */
struct addr c_bindaddr; /* local addr to bind to */
int c_ipv4_maxwidth; /* widest dropable IPv4 cidr block */
int c_ipv6_maxwidth; /* widest dropable IPv4 cidr block */
char *c_cuser; /* connect username */
char *c_cpass1; /* primary connect password */
char *c_cpass2; /* backup connect password */
char *c_euser; /* enable username */
char *c_epass1; /* primary enable password */
char *c_epass2; /* backup enable password */
char *c_expect; /* pathname expect binary */
char *c_router; /* ip addr or hostname of router */
char *c_script; /* pathname expect binary */
char *c_id; /* optional NETS log id */
#ifdef HAVE_BROCCOLI
struct addr c_broaddr; /* broccoli listen address */
int c_portbro; /* broccoli listen port */
#endif
#ifdef HAVE_CFORCE
char *c_cforceaddr; /* cForce device ip addr or hostname */
char *c_cforcedata; /* cForce saved data file location */
int c_portcforce; /* cForce device port */
#endif
struct acllimit *c_acllimit;
size_t c_acllimitlen;
size_t c_acllimitsize;
struct acllist *c_acllist;
size_t c_acllistlen;
size_t c_acllistsize;
struct attrlist *c_attrlist;
size_t c_attrlistlen;
size_t c_attrlistsize;
struct intlist *c_intlist;
size_t c_intlistlen;
size_t c_intlistsize;
struct route *c_nullzeronets;
size_t c_nullzeronetslen;
size_t c_nullzeronetssize;
char *c_whitelistfn;
struct addr *c_whitelist;
size_t c_whitelistlen;
size_t c_whitelistsize;
};
void freecf(struct cf *);
struct cf *parsecf(const char *);
#endif