blob: bc48466bc7188c8009bf9040c69d5d895eee6cc3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
.\" $NetBSD$
.\"
.TH IPMON 5
.SH NAME
ipmon, ipmon.conf \- ipmon configuration file format
.SH DESCRIPTION
The format for files accepted by ipmon is described by the following grammar:
.LP
.nf
"match" "{" matchlist "}" "do" "{" doing "}" ";"
matchlist ::= matching [ "," matching ] .
matching ::= direction | dstip | dstport | every | group | interface |
logtag | nattag | protocol | result | rule | srcip | srcport .
dolist ::= doing [ "," doing ] .
doing ::= execute | save | syslog .
direction ::= "in" | "out" .
dstip ::= "dstip" "=" ipv4 "/" number .
dstport ::= "dstport" "=" number .
every ::= "every" every-options .
execute ::= "execute" "=" string .
group ::= "group" "=" string | "group" "=" number .
interface ::= "interface" "=" string .
logtag ::= "logtag" "=" string | "logtag" "=" number .
nattag ::= "nattag" "=" string .
protocol ::= "protocol" "=" string | "protocol" "=" number .
result ::= "result" "=" result-option .
rule ::= "rule" "=" number .
srcip ::= "srcip" "=" ipv4 "/" number .
srcport ::= "srcport" "=" number .
type ::= "type" "=" ipftype .
ipv4 ::= number "." number "." number "." number .
every-options ::= "second" | number "seconds" | "packet" | number "packets" .
result-option ::= "pass" | "block" | "short" | "nomatch" | "log" .
ipftype ::= "ipf" | "nat" | "state" .
.fi
.PP
In addition, lines that start with a # are considered to be comments.
.TP
.SH OVERVIEW
.PP
The ipmon configuration file is used for defining rules to be executed when
logging records are read from
.B /dev/ipl.
.PP
At present, only IPv4 matching is available for source/destination address
matching.
.SH MATCHING
.PP
Each rule for ipmon consists of two primary segments: the first describes how
the log record is to be matched, the second defines what action to take if
there is a positive match. All entries of the rules present in the file are
compared for matches - there is no first or last rule match.
.SH FILES
/dev/ipl
.br
/dev/ipf
.br
/dev/ipnat
.br
/dev/ipstate
.br
/etc/ipmon.conf
.SH SEE ALSO
ipmon(8), ipl(4)
|