Changeset View
Changeset View
Standalone View
Standalone View
sbin/ipfw/ipfw2.h
Show All 14 Lines | |||||
* | * | ||||
* This software is provided ``AS IS'' without any warranties of any kind. | * This software is provided ``AS IS'' without any warranties of any kind. | ||||
* | * | ||||
* NEW command line interface for IP firewall facility | * NEW command line interface for IP firewall facility | ||||
* | * | ||||
* $FreeBSD$ | * $FreeBSD$ | ||||
*/ | */ | ||||
enum cmdline_prog { | |||||
cmdline_prog_ipfw, | |||||
cmdline_prog_dnctl | |||||
}; | |||||
/* | /* | ||||
* Options that can be set on the command line. | * Options that can be set on the command line. | ||||
* When reading commands from a file, a subset of the options can also | * When reading commands from a file, a subset of the options can also | ||||
* be applied globally by specifying them before the file name. | * be applied globally by specifying them before the file name. | ||||
* After that, each line can contain its own option that changes | * After that, each line can contain its own option that changes | ||||
* the global value. | * the global value. | ||||
* XXX The context is not restored after each line. | * XXX The context is not restored after each line. | ||||
*/ | */ | ||||
Show All 18 Lines | struct cmdline_opts { | ||||
int do_dynamic; /* 1 - display dynamic rules */ | int do_dynamic; /* 1 - display dynamic rules */ | ||||
/* 2 - display/delete only dynamic rules */ | /* 2 - display/delete only dynamic rules */ | ||||
int do_sort; /* field to sort results (0 = no) */ | int do_sort; /* field to sort results (0 = no) */ | ||||
/* valid fields are 1 and above */ | /* valid fields are 1 and above */ | ||||
uint32_t use_set; /* work with specified set number */ | uint32_t use_set; /* work with specified set number */ | ||||
/* 0 means all sets, otherwise apply to set use_set - 1 */ | /* 0 means all sets, otherwise apply to set use_set - 1 */ | ||||
enum cmdline_prog prog; /* Are we ipfw or dnctl? */ | |||||
}; | }; | ||||
int is_ipfw(void); | |||||
enum { | enum { | ||||
TIMESTAMP_NONE = 0, | TIMESTAMP_NONE = 0, | ||||
TIMESTAMP_STRING, | TIMESTAMP_STRING, | ||||
TIMESTAMP_NUMERIC, | TIMESTAMP_NUMERIC, | ||||
}; | }; | ||||
extern struct cmdline_opts g_co; | extern struct cmdline_opts g_co; | ||||
▲ Show 20 Lines • Show All 389 Lines • Show Last 20 Lines |