Changeset View
Changeset View
Standalone View
Standalone View
sys/netinet/libalias/alias_local.h
Show First 20 Lines • Show All 74 Lines • ▼ Show 20 Lines | |||||
#ifdef _KERNEL | #ifdef _KERNEL | ||||
#define INET_NTOA_BUF(buf) (buf) | #define INET_NTOA_BUF(buf) (buf) | ||||
#else | #else | ||||
#define INET_NTOA_BUF(buf) (buf), sizeof(buf) | #define INET_NTOA_BUF(buf) (buf), sizeof(buf) | ||||
#endif | #endif | ||||
struct proxy_entry; | struct proxy_entry; | ||||
struct group_in { | |||||
struct in_addr alias_addr; | |||||
u_short alias_port; | |||||
int link_type; | |||||
LIST_ENTRY(group_in) group_in; | |||||
LIST_HEAD(, alias_link) full, partial; | |||||
}; | |||||
struct libalias { | struct libalias { | ||||
LIST_ENTRY(libalias) instancelist; | LIST_ENTRY(libalias) instancelist; | ||||
/* Mode flags documented in alias.h */ | /* Mode flags documented in alias.h */ | ||||
int packetAliasMode; | int packetAliasMode; | ||||
/* Address written onto source field of IP packet. */ | /* Address written onto source field of IP packet. */ | ||||
struct in_addr aliasAddress; | struct in_addr aliasAddress; | ||||
/* IP address incoming packets are sent to | /* IP address incoming packets are sent to | ||||
* if no aliasing link already exists */ | * if no aliasing link already exists */ | ||||
struct in_addr targetAddress; | struct in_addr targetAddress; | ||||
/* Lookup table of pointers to chains of link records. | /* Lookup table of pointers to chains of link records. | ||||
* Each link record is doubly indexed into input and | * Each link record is doubly indexed into input and | ||||
* output lookup tables. */ | * output lookup tables. */ | ||||
LIST_HEAD (, alias_link) linkTableOut[LINK_TABLE_OUT_SIZE]; | LIST_HEAD (, alias_link) linkTableOut[LINK_TABLE_OUT_SIZE]; | ||||
LIST_HEAD (, alias_link) linkTableIn[LINK_TABLE_IN_SIZE]; | LIST_HEAD (, group_in) groupTableIn[LINK_TABLE_IN_SIZE]; | ||||
LIST_HEAD (, alias_link) pptpTable; | |||||
/* HouseKeeping */ | /* HouseKeeping */ | ||||
TAILQ_HEAD (, alias_link) checkExpire; | TAILQ_HEAD (, alias_link) checkExpire; | ||||
/* Link statistics */ | /* Link statistics */ | ||||
int icmpLinkCount; | int icmpLinkCount; | ||||
int udpLinkCount; | int udpLinkCount; | ||||
int tcpLinkCount; | int tcpLinkCount; | ||||
int pptpLinkCount; | int pptpLinkCount; | ||||
int protoLinkCount; | int protoLinkCount; | ||||
▲ Show 20 Lines • Show All 280 Lines • Show Last 20 Lines |