1SHOREWALL6-POLICY(5)            [FIXME: manual]           SHOREWALL6-POLICY(5)
2
3
4

NAME

6       policy - shorewall6 policy file
7

SYNOPSIS

9       /etc/shorewall6/policy
10

DESCRIPTION

12       This file defines the high-level policy for connections between zones
13       defined in shorewall6-zones[1](5).
14
15           Important
16           The order of entries in this file is important
17
18           This file determines what to do with a new connection request if we
19           don't get a match from the /etc/shorewall6/rules file . For each
20           source/destination pair, the file is processed in order until a
21           match is found ("all" will match any client or server).
22
23           Important
24           Intra-zone policies are pre-defined
25
26           For $FW and for all of the zones defined in /etc/shorewall6/zones,
27           the POLICY for connections from the zone to itself is ACCEPT (with
28           no logging or TCP connection rate limiting but may be overridden by
29           an entry in this file. The overriding entry must be explicit
30           (cannot use "all" in the SOURCE or DEST).
31
32           Similarly, if you have IMPLICIT_CONTINUE=Yes in shorewall6.conf,
33           then the implicit policy to/from any sub-zone is CONTINUE. These
34           implicit CONTINUE policies may also be overridden by an explicit
35           entry in this file.
36
37       The columns in the file are as follows.
38
39       SOURCE - zone|$FW|all
40           Source zone. Must be the name of a zone defined in
41           shorewall6-zones[1](5), $FW or "all".
42
43       DEST - zone|$FW|all
44           Destination zone. Must be the name of a zone defined in
45           shorewall6-zones[1](5), $FW or "all". If the DEST is a bport zone,
46           then the SOURCE must be "all", another bport zone associated with
47           the same bridge, or it must be an ipv6 zone that is associated with
48           only the same bridge.
49
50       POLICY -
51       {ACCEPT|DROP|REJECT|CONTINUE|QUEUE|NFQUEUE[(queuenumber)]|NONE}[:{default-action-or-macro|None}]
52           Policy if no match from the rules file is found.
53
54           If the policy is other than CONTINUE or NONE then the policy may be
55           followed by ":" and one of the following:
56
57            1. The word "None" or "none". This causes any default action
58               defined in shorewall6.conf[2](5) to be omitted for this policy.
59
60            2. The name of an action (requires that USE_ACTIONS=Yes in
61               shorewall6.conf[2](5)). That action will be invoked before the
62               policy is enforced.
63
64            3. The name of a macro. The rules in that macro will be applied
65               before the policy is enforced. This does not require
66               USE_ACTIONS=Yes.
67
68
69           Possible policies are:
70
71           ACCEPT
72               Accept the connection.
73
74           DROP
75               Ignore the connection request.
76
77           REJECT
78               For TCP, send RST. For all other, send an "unreachable" ICMP.
79
80           QUEUE
81               Queue the request for a user-space application such as
82               Snort-inline.
83
84           NFQUEUE
85               Queue the request for a user-space application using the
86               nfnetlink_queue mechanism. If a queuenumber is not given, queue
87               zero (0) is assumed.
88
89           CONTINUE
90               Pass the connection request past any other rules that it might
91               also match (where the source or destination zone in those rules
92               is a superset of the SOURCE or DEST in this policy). See
93               shorewall6-nesting[3](5) for additional information.
94
95           NONE
96               Assume that there will never be any packets from this SOURCE to
97               this DEST. shorewall6 will not create any infrastructure to
98               handle such packets and you may not have any rules with this
99               SOURCE and DEST in the /etc/shorewall6/rules file. If such a
100               packet is received, the result is undefined. NONE may not be
101               used if the SOURCE or DEST columns contain the firewall zone
102               ($FW) or "all".
103
104       LOG LEVEL (Optional) - [log-level|NFLOG]
105           If supplied, each connection handled under the default POLICY is
106           logged at that level. If not supplied, no log message is generated.
107           See syslog.conf(5) for a description of log levels.
108
109           You may also specify NFLOG (must be in upper case). This will log
110           to the NFLOG target and will send to a separate log through use of
111           ulogd (http://www.netfilter.org/projects/ulogd/index.html).
112
113           If you don't want to log but need to specify the following column,
114           place "-" here.
115
116       BURST:LIMIT - [{s|d}:[[name]:]]]rate/{second|minute}[:burst]
117           If passed, specifies the maximum TCP connection rate and the size
118           of an acceptable burst. If not specified, TCP connections are not
119           limited. If the burst parameter is omitted, a value of 5 is
120           assumed.
121
122           When s: or d: is specified, the rate applies per source IP address
123           or per destination IP address respectively. The name may be chosen
124           by the user and specifies a hash table to be used to count matching
125           connections. If not give, the name shorewall is assumed. Where more
126           than one POLICY specifies the same name, the connections counts for
127           the policies are aggregated and the individual rates apply to the
128           aggregated count.
129
130       CONNLIMIT - limit[:mask]
131           May be used to limit the number of simultaneous connections from
132           each individual host to limit connections. While the limit is only
133           checked on connections to which this policy could apply, the number
134           of current connections is calculated over all current connections
135           from the SOURCE host. By default, the limit is applied to each host
136           individually but can be made to apply to networks of hosts by
137           specifying a mask. The mask specifies the width of a VLSM mask to
138           be applied to the source address; the number of current connections
139           is then taken over all hosts in the subnet source-address/mask.
140

EXAMPLE

142        1. All connections from the local network to the internet are allowed
143
144        2. All connections from the internet are ignored but logged at syslog
145           level KERNEL.INFO.
146
147        3. All other connection requests are rejected and logged at level
148           KERNEL.INFO.
149
150                   #SOURCE         DEST            POLICY          LOG           BURST:LIMIT
151                   #                                               LEVEL
152                   loc             net             ACCEPT
153                   net             all             DROP            info
154                   #
155                   # THE FOLLOWING POLICY MUST BE LAST
156                   #
157                   all             all             REJECT          info
158

FILES

160       /etc/shorewall6/policy
161

SEE ALSO

163       shorewall6(8), shorewall6-accounting(5), shorewall6-actions(5),
164       shorewall6-blacklist(5), shorewall6-hosts(5), shorewall6-interfaces(5),
165       shorewall6-ipsec(5), shorewall6-maclist(5), shorewall6-masq(5),
166       shorewall6-nat(5), shorewall6-netmap(5), shorewall6-params(5),
167       shorewall6-policy(5), shorewall6-providers(5), shorewall6-proxyarp(5),
168       shorewall6-route_rules(5), shorewall6-routestopped(5),
169       shorewall6-rules(5), shorewall6.conf(5), shorewall6-secmarks(5),
170       shorewall6-tcclasses(5), shorewall6-tcdevices(5),
171       shorewall6-tcrules(5), shorewall6-tos(5), shorewall6-tunnels(5),
172       shorewall6-zones(5)
173

NOTES

175        1. shorewall6-zones
176           http://www.shorewall.net/manpages6/shorewall6-zones.html
177
178        2. shorewall6.conf
179           http://www.shorewall.net/manpages6/shorewall6.conf.html
180
181        3. shorewall6-nesting
182           http://www.shorewall.net/manpages6/shorewall6-nesting.html
183
184
185
186[FIXME: source]                   09/16/2011              SHOREWALL6-POLICY(5)
Impressum