{"id":4377,"date":"2022-12-20T17:49:07","date_gmt":"2022-12-20T20:49:07","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/shorewallrules-man5\/"},"modified":"2022-12-20T17:49:07","modified_gmt":"2022-12-20T20:49:07","slug":"shorewallrules-man5","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/shorewallrules-man5\/","title":{"rendered":"SHOREWALL&minus;RULES (man5)"},"content":{"rendered":"<h1 align=\"center\">SHOREWALL\u2212RULES<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#DESCRIPTION\">DESCRIPTION<\/a><br \/> <a href=\"#EXAMPLES\">EXAMPLES<\/a><br \/> <a href=\"#FILES\">FILES<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a><br \/> <a href=\"#NOTES\">NOTES<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">rules \u2212 Shorewall rules file<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"35%\">\n<p style=\"margin-top: 1em\"><b>\/etc\/shorewall[6]\/rules<\/b><\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Entries in this file govern connection establishment by defining exceptions to the policies laid out in <b><font color=\"#0000FF\">shorewall\u2212policy<\/font><\/b> <small><font color=\"#000000\">[1]<\/font><\/small> <font color=\"#000000\">(5). By default, subsequent requests and responses are automatically allowed using connection tracking. For any particular (source,dest) pair of zones, the rules are evaluated in the order in which they appear in this file and the first terminating match is the one that determines the disposition of the request. All rules are terminating except LOG and COUNT rules.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b><big>Warning<\/big><\/b> <br \/> If you masquerade or use SNAT from a local system to the internet, you cannot use an ACCEPT rule to allow traffic from the internet to that system. You <b>must<\/b> use a DNAT rule instead.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">The rules file is divided into sections. Each section is introduced by a &#8220;Section Header&#8221; which is a line beginning with ?SECTION and followed by the section name.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">Sections are as follows and must appear in the order listed:<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>ALL<\/b><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">This section was added in Shorewall 4.4.23. Rules in this section are applied, regardless of the connection tracking state of the packet and are applied before rules in the other sections.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>ESTABLISHED<\/b><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Packets in the ESTABLISHED state are processed by rules in this section.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The only ACTIONs allowed in this section are ACCEPT, DROP, REJECT, LOG, NFLOG, NFQUEUE and QUEUE<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">There is an implicit ACCEPT rule inserted at the end of this section.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>RELATED<\/b><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Packets in the RELATED state are processed by rules in this section.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The only ACTIONs allowed in this section are ACCEPT, DROP, REJECT, LOG, NFLOG, NFQUEUE and QUEUE<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">There is an implicit rule added at the end of this section that invokes the RELATED_DISPOSITION (<\/font><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5)).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>INVALID<\/b><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Added in Shorewall 4.5.13. Packets in the INVALID state are processed by rules in this section.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The only Actions allowed in this section are ACCEPT, DROP, REJECT, LOG, NFLOG, NFQUEUE and QUEUE.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">There is an implicit rule added at the end of this section that invokes the INVALID_DISPOSITION (<\/font><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5)).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>UNTRACKED<\/b><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Added in Shorewall 4.5.13. Packets in the UNTRACKED state are processed by rules in this section.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The only Actions allowed in this section are ACCEPT, DROP, REJECT, LOG, NFLOG, NFQUEUE and QUEUE.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">There is an implicit rule added at the end of this section that invokes the UNTRACKED_DISPOSITION (<\/font><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5)).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>NEW<\/b><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Packets in the NEW state are processed by rules in this section. If the INVALID and\/or UNTRACKED sections are empty or not included, then the packets in the corresponding state(s) are also processed in this section.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b><big>Note<\/big><\/b> <br \/> If you are not familiar with Netfilter to the point where you are comfortable with the differences between the various connection tracking states, then it is suggested that you place all of your rules in the NEW section (That&#8217;s after the line that reads ?SECTION NEW&#8217;).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b><big>Warning<\/big><\/b> <br \/> If you specify FASTACCEPT=Yes in<\/font> <b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5) then the <b>ALL, ESTABLISHED<\/b> and <b>RELATED<\/b> sections must be empty.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">An exception is made if you are running Shorewall 4.4.27 or later and you have specified a non\u2212default value for RELATED_DISPOSITION or RELATED_LOG_LEVEL. In that case, you may have rules in the RELATED section of this file.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">You may omit any section that you don&#8217;t need. If no Section Headers appear in the file then all rules are assumed to be in the NEW section.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">When defining rules that rewrite the destination IP address and\/or port number (namely DNAT and REDIRECT rules), it is important to keep straight which columns in the file specify the packet before rewriting and which specify how the packet will look after rewriting.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">\u2022 The DEST column specifies the final destination for the packet after rewriting and can include the final IP address and\/or port number.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">\u2022 The remaining columns specify characteristics of the packet before rewriting. In particular, the ORIGDEST column gives the original destination IP address of the packet and the DPORT column give the original destination port(s).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">The columns in the file are as follows (where the column name is followed by a different name in parentheses, the different name is used in the alternate specification syntax).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>ACTION<\/b> \u2212 <i>target<\/i><b>[:<\/b>{<i>log\u2212level<\/i>|<b>none<\/b>}[<b>!<\/b>][<b>:<\/b><i>tag<\/i>]]<\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specifies the action to be taken if the connection request matches the rule. <i>target<\/i> must be one of the following.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>ACCEPT<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Allow the connection request.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>ACCEPT+<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">like ACCEPT but also excludes the connection from any subsequent matching <b>DNAT<\/b>[<b>\u2212<\/b>] or <b>REDIRECT<\/b>[<b>\u2212<\/b>] rules. Use with IPv6 requires Shorewall 4.5.14 or later.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>ACCEPT!<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">like ACCEPT but exempts the rule from being suppressed by OPTIMIZE=1 in<\/font> <b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><i>action<\/i><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">The name of an <i>action<\/i> declared in<\/font> <b><font color=\"#0000FF\">shorewall\u2212actions<\/font><\/b> <small><font color=\"#000000\">[3]<\/font><\/small> <font color=\"#000000\">(5) or in \/usr\/share\/shorewall[6]\/actions.std.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>ADD(<\/b><i>ipset<\/i><b>:<\/b><i>flags<\/i><b>[:<\/b><i>timeout<\/i><b>])<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.4.12. Causes addresses and\/or port numbers to be added to the named <i>ipset<\/i>. The <i>flags<\/i> specify the address or tuple to be added to the set and must match the type of ipset involved. For example, for an iphash ipset, either the SOURCE or DESTINATION address can be added using <i>flags<\/i> <b>src<\/b> or <b>dst<\/b> respectively (see the \u2212A command in ipset (8)).<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">Beginning with Shorewall 5.0.3, an optional <i>timeout<\/i> can be specified. This is the number of seconds that the new entry in the ipset is to remain valid and overrides any timeout specified when the ipset was created.<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">ADD is non\u2212terminating. Even if a packet matches the rule, it is passed on to the next rule.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>AUDIT<\/b>[(accept|drop|reject)]<\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.5.10. Audits the packet with the specified type; if the type is omitted, then <b>drop<\/b> is assumed. Require AUDIT_TARGET support in the kernel and iptables.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>A_ACCEPT<\/b>, <b>A_ACCEPT+<\/b> and <b>A_ACCEPT!<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.4.20. Audited versions of ACCEPT, ACCEPT+ and ACCEPT! respectively. Require AUDIT_TARGET support in the kernel and iptables. A_ACCEPT+ with IPv6 requires Shorewall 4.5.14 or later.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>A_DROP<\/b> and <b>A_DROP!<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.4.20. Audited versions of DROP and DROP! respectively. Require AUDIT_TARGET support in the kernel and iptables.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>A_REJECT<\/b> AND <b>A_REJECT!<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.4.20. Audited versions of REJECT and REJECT! respectively. Require AUDIT_TARGET support in the kernel and iptables.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>?COMMENT<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">the rest of the line will be attached as a comment to the Netfilter rule(s) generated by the following entries. The comment will appear delimited by &#8220;\/* &#8230; *\/&#8221; in the output of &#8220;shorewall show <chain>&#8220;. To stop the comment from being attached to further rules, simply include ?COMMENT on a line by itself.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>CONMARK({<\/b><i>mark<\/i><b>})<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 5.0.7, CONNMARK is identical to MARK with the exception that the mark is assigned to connection to which the packet belongs is marked rather than to the packet itself.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>CONTINUE<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">For experts only.<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">Do not process any of the following rules for this (source zone,destination zone). If the source and\/or destination IP address falls into a zone defined later in<\/font> <b><font color=\"#0000FF\">shorewall\u2212zones<\/font><\/b> <small><font color=\"#000000\">[4]<\/font><\/small> <font color=\"#000000\">(5) or in a parent zone of the source or destination zones, then this connection request will be passed to the rules defined for that (those) zone(s). See<\/font> <b><font color=\"#0000FF\">shorewall\u2212nesting<\/font><\/b> <small><font color=\"#000000\">[5]<\/font><\/small> <font color=\"#000000\">(5) for additional information.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>CONTINUE!<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">like CONTINUE but exempts the rule from being suppressed by OPTIMIZE=1 in<\/font> <b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>COUNT<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Simply increment the rule&#8217;s packet and byte count and pass the packet to the next rule.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>DEL(<\/b><i>ipset<\/i><b>:<\/b><i>flags<\/i><b>)<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.4.12. Causes an entry to be deleted from the named <i>ipset<\/i>. The <i>flags<\/i> specify the address or tuple to be deleted from the set and must match the type of ipset involved. For example, for an iphash ipset, either the SOURCE or DESTINATION address can be deleted using <i>flags<\/i> <b>src<\/b> or <b>dst<\/b> respectively (see the \u2212D command in ipset (8)).<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">DEL is non\u2212terminating. Even if a packet matches the rule, it is passed on to the next rule.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>DNAT<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Forward the request to another system (and optionally another port). Use with IPv6 requires Shorewall 4.5.14 or later.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>DNAT\u2212<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Advanced users only.<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">Like <b>DNAT<\/b> but only generates the <b>DNAT<\/b> iptables rule and not the companion <b>ACCEPT<\/b> rule. Use with IPv6 requires Shorewall 4.5.14 or later.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>DROP<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Ignore the request.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>DROP!<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">like DROP but exempts the rule from being suppressed by OPTIMIZE=1 in<\/font> <b><font color=\"#0000FF\">shorewall.conf<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">(5).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>HELPER<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.5.7. This action requires that the HELPER column contains the name of the Netfilter helper to be associated with connections matching this connection. May only be specified in the NEW section and is useful for being able to specify a helper when the applicable policy is ACCEPT. No destination zone should be specified in HELPER rules.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>INLINE<\/b>[(<i>action<\/i>)]<\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">Added in Shorewall 4.5.16. This action allows you to construct most of the rule yourself using iptables syntax. The part that you specify must follow two semicolons (&#8216;;;&#8217;) and is completely free\u2212form. If the target of the rule (the part following &#8216;j&#8217;) is something that Shorewall supports in the ACTION column, then you may enclose it in parentheses (e.g., INLINE(ACCEPT)). Otherwise, you can include it after the semicolon(s). In this case, you must declare the target as a builtin action in<\/font> <b><font color=\"#0000FF\">shorewall\u2212actions<\/font><\/b> <small><font color=\"#000000\">[3]<\/font><\/small> <font color=\"#000000\">(5).<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">Some considerations when using INLINE:<\/font><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><font color=\"#000000\">\u2022 The <b>p<\/b>, <b>s<\/b>, <b>d<\/b>, <b>i<\/b>, <b>o<\/b>, <b>policy<\/b>, and state match (<b>state<\/b> or <b>conntrack \u2212\u2212ctstate<\/b>) matches will always appear in the front of the rule in that order.<\/font><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><font color=\"#000000\">\u2022 When multiple matches are specified, the compiler will keep them in the order in which they appear (excluding the above listed ones), but they will not necessarily be at the end of the generated rule. For example, if addresses are specified in the SOURCE and\/or DEST columns, their generated matches will appear after those specified using &#8216;;;&#8217; or &#8216;;&#8217;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>IPTABLES<\/b>({<i>iptables\u2212target<\/i> [<i>option<\/i> &#8230;])<\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">IPv4 only. This action allows you to specify an iptables target with options (e.g., &#8216;IPTABLES(MARK \u2212\u2212set\u2212xmark 0x01\/0xff)&#8217;. If the <i>iptables\u2212target<\/i> is not one recognized by Shorewall, the following error message will be issued:<\/font><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><font color=\"#000000\">ERROR: Unknown target (<i>iptables\u2212target<\/i>)<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">This error message may be eliminated by adding the <i>iptables\u2212target<\/i> as a builtin action in<\/font> <b><font color=\"#0000FF\">shorewall\u2212actions<\/font><\/b> <small><font color=\"#000000\">[3]<\/font><\/small> <font color=\"#000000\">(5).<\/font><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><font color=\"#000000\"><b><big>Important<\/big><\/b> <br \/> If you specify REJECT as the <i>iptables\u2212target<\/i>, the target of the rule will be the iptables REJECT target and not Shorewall&#8217;s builtin &#8216;reject&#8217; chain which is used when REJECT (see below) is specified as the <i>target<\/i> in the ACTION column.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b><big>IP6TABLES<\/big><\/b><big>({<i>ip6tables\u2212target<\/i> [<i>option<\/i> &#8230;])<\/big><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\"><big>IPv6 only. This action allows you to specify an ip6tables target with options (e.g., &#8216;IPTABLES(MARK \u2212\u2212set\u2212xmark 0x01\/0xff)&#8217;. If the <i>ip6tables\u2212target<\/i> is not one recognized by Shorewall, the following error message will be issued:<\/big><\/font><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><font color=\"#000000\"><big>ERROR: Unknown target (<i>ip6tables\u2212target<\/i>)<\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big>This error message may be eliminated by adding the <i>ip6tables\u2212target<\/i> as a builtin action in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212actions<\/font><\/b><\/big> <font color=\"#000000\">[3] <big>(5).<\/big><\/font><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><font color=\"#000000\"><big><b><big>Important<\/big><\/b> <br \/> If you specify REJECT as the <i>ip6tables\u2212target<\/i>, the target of the rule will be the i6ptables REJECT target and not Shorewall&#8217;s builtin &#8216;reject&#8217; chain which is used when REJECT (see below) is specified as the <i>target<\/i> in the ACTION column.<\/big><\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><big><b><big>LOG:<\/big><\/b><big><i>level<\/i><\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\"><big><big>Simply log the packet and continue with the next rule.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><big><big><i>macro<\/i><b>[(<\/b><i>macrotarget<\/i><b>)]<\/b><\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\"><big><big>The name of a macro defined in a file named macro.<i>macro<\/i>. If the macro accepts an action parameter (Look at the macro source to see if it has PARAM in the TARGET column) then the <i>macro<\/i> name is followed by the parenthesized <i>macrotarget<\/i> (<b>ACCEPT<\/b>, <b>DROP<\/b>, <b>REJECT<\/b>, &#8230;) to be substituted for the parameter.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big><big>Example: FTP(ACCEPT).<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big><big>The older syntax where the macro name and the target are separated by a slash (e.g. FTP\/ACCEPT) is still allowed but is deprecated.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><big><big><b>MARK({<\/b><i>mark<\/i><b>})<\/b><\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\"><big><big>where <i>mark<\/i> is a packet mark value.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big><big>Added in Shorewall 5.0.7, MARK requires &#8220;Mark in filter table&#8221; support in your kernel and iptables.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big><big>Normally will set the mark value of the current packet. If preceded by a vertical bar (&#8220;|&#8221;), the mark value will be logically ORed with the current mark value to produce a new mark value. If preceded by an ampersand (&#8220;&#038;&#8221;), will be logically ANDed with the current mark value to produce a new mark value.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big><big>Both &#8220;|&#8221; and &#8220;&#038;&#8221; require Extended MARK Target support in your kernel and iptables.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\"><big><big>The mark value may be optionally followed by &#8220;\/&#8221; and a mask value (used to determine those bits of the connection mark to actually be set). When a mask is specified, the result of logically ANDing the mark value with the mask must be the same as the mark value.<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><big><big><b>NFLOG<\/b>[(<i>nflog\u2212parameters<\/i>)]<\/big><\/big><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\"><big><big>Added in Shorewall 4.5.9.3. Queues matching packets to a back end logging daemon via a netlink socket then continues to the next rule. See<\/big><\/big><\/font> <big><big><b><font color=\"#0000FF\">https:\/\/shorewall.org\/shorewall_logging.html<\/font><\/b><\/big> <font color=\"#000000\">[6] <big>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>The <i>nflog\u2212parameters<\/i> are a comma\u2212separated list of up to 3 numbers:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The first number specifies the netlink group (0\u221265535). If omitted (e.g., NFLOG(,0,10)) then a value of 0 is assumed.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The second number specifies the maximum number of bytes to copy. If omitted, 0 (no limit) is assumed.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The third number specifies the number of log messages that should be buffered in the kernel before they are sent to user space. The default is 1.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>NFLOG is similar to <b>LOG:NFLOG<\/b>[(<i>nflog\u2212parameters<\/i>)], except that the log level is not changed when this ACTION is used in an action or macro body and the invocation of that action or macro specifies a log level.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>NFQUEUE<\/b>[([<i>queuenumber<\/i>1[:<i>queuenumber2<\/i>[c]][,bypass]]|bypass)]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Queues the packet to a user\u2212space application using the nfnetlink_queue mechanism. If a <i>queuenumber<\/i>1 is not specified, queue zero (0) is assumed. Beginning with Shorewall 4.6.10, the keyword <b>bypass<\/b> can be given. By default, if no userspace program is listening on an NFQUEUE, then all packets that are to be queued are dropped. When this option is used, the NFQUEUE rule behaves like ACCEPT instead. Also beginning in Shorewall 4.6.10, a second queue number (<i>queuenumber2<\/i>) may be specified. This specifies a range of queues to use. Packets are then balanced across the given queues. This is useful for multicore systems: start multiple instances of the userspace program on queues x, x+1, .. x+n and use &#8220;x:x+n&#8221;. Packets belonging to the same connection are put into the same nfqueue.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 5.1.0, queuenumber2 may be followed by the letter &#8216;c&#8217; to indicate that the CPU ID will be used as an index to map packets to the queues. The idea is that you can improve performance if there&#8217;s a queue per CPU. Requires the NFQUEUE CPU Fanout capability in your kernel and iptables.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>NFQUEUE![([<\/b><i>queuenumber1<\/i><b>[:<\/b><i>queuenumber2<\/i><b>[c]][,bypass]]|bypass)]<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>like NFQUEUE but exempts the rule from being suppressed by OPTIMIZE=1 in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b><\/big> <font color=\"#000000\">[2] <big>(5).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>NONAT<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Excludes the connection from any subsequent <b>DNAT<\/b>[\u2212] or <b>REDIRECT<\/b>[\u2212] rules but doesn&#8217;t generate a rule to accept the traffic. Use with IPv6 requires Shorewall 4.5.14 or later.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>QUEUE<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Queue the packet to a user\u2212space application such as ftwall (http:\/\/p2pwall.sf.net). The application may reinsert the packet for further processing.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>QUEUE!<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>like QUEUE but exempts the rule from being suppressed by OPTIMIZE=1 in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b><\/big> <font color=\"#000000\">[2] <big>(5).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>REJECT[(<\/b><i>option<\/i><b>)]<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>disallow the request and return an icmp\u2212unreachable or an RST packet. If no option is passed, Shorewall selects the appropriate option based on the protocol of the packet.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 5.0.8, the type of reject may be specified in the <i>option<\/i> paramater. Valid IPv4 <i>option<\/i> values are:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big><b>icmp\u2212net\u2212unreachable <br \/> icmp\u2212host\u2212unreachable <br \/> icmp\u2212port\u2212unreachable <br \/> icmp\u2212proto\u2212unreachable <br \/> icmp\u2212net\u2212prohibited <br \/> icmp\u2212host\u2212prohibited <br \/> icmp\u2212admin\u2212prohibited <br \/> icmp\u2212tcp\u2212reset<\/b> (the PROTO column <br \/> must specify TCP). Beginning with Shorewall 5.1.3, this <br \/> option may also be specified as <b><br \/> tcp\u2212reset<\/b>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Valid IPv6 <i>option<\/i> values are:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big><b>icmp6\u2212no\u2212route <br \/> no\u2212route <br \/> icmp6\u2212adm\u2212prohibited <br \/> adm\u2212prohibited <br \/> icmp6\u2212addr\u2212unreachable <br \/> addr\u2212unreach <br \/> icmp6\u2212port\u2212unreachable <br \/> tcp\u2212reset<\/b> (the PROTO column must <br \/> specify TCP)<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>REJECT!<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>like REJECT but exempts the rule from being suppressed by OPTIMIZE=1 in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b><\/big> <font color=\"#000000\">[2] <big>(5).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>REDIRECT<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Redirect the request to a server running on the firewall. Use with IPv6 requires Shorewall 4.5.14 or later.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>REDIRECT\u2212<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Advanced users only.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Like <b>REDIRECT<\/b> but only generates the <b>REDIRECT<\/b> iptables rule and not the companion <b>ACCEPT<\/b> rule. Use with IPv6 requires Shorewall 4.5.14 or later.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>TARPIT<\/b> [(<b>tarpit<\/b> | <b>honeypot<\/b> | <b>reset<\/b>)]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Added in Shorewall 4.6.6.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>TARPIT captures and holds incoming TCP connections using no local per\u2212connection resources.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>TARPIT only works with the PROTO column set to tcp (6), and is totally application agnostic. This module will answer a TCP request and play along like a listening server, but aside from sending an ACK or RST, no data is sent. Incoming packets are ignored and dropped. The attacker will terminate the session eventually. This module allows the initial packets of an attack to be captured by other software for inspection. In most cases this is sufficient to determine the nature of the attack.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>This offers similar functionality to LaBrea <http:\/\/www.hackbusters.net\/LaBrea\/> but does not require dedicated hardware or IPs. Any TCP port that you would normally DROP or REJECT can instead become a tarpit.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>The target accepts a single optional parameter:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>tarpit<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big>This mode is the default and completes a connection with the attacker but limits the window size to 0, thus keeping the attacker waiting long periods of time. While he is maintaining state of the connection and trying to continue every 60\u2212240 seconds, we keep none, so it is very lightweight. Attempts to close the connection are ignored, forcing the remote side to time out the connection in 12\u221224 minutes.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>honeypot<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big>This mode completes a connection with the attacker, but signals a normal window size, so that the remote side will attempt to send data, often with some very nasty exploit attempts. We can capture these packets for decoding and further analysis. The module does not send any data, so if the remote expects an application level response, the game is up.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>reset<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big>This mode is handy because we can send an inline RST (reset). It has no other function.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>ULOG<\/b>[(<i>ulog\u2212parameters<\/i>)]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>IPv4 only. Added in Shorewall 4.5.10. Queues matching packets to a back end logging daemon via a netlink socket then continues to the next rule. See<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212logging(5)<\/font><\/b><\/big> <font color=\"#000000\">[7] <big>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Similar to <b>LOG:ULOG<\/b>[(<i>ulog\u2212parameters<\/i>)], except that the log level is not changed when this ACTION is used in an action or macro body and the invocation of that action or macro specifies a log level.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>The <i>target<\/i> may optionally be followed by &#8220;:&#8221; and a syslog log level (e.g, REJECT:info or Web(ACCEPT):debug). This causes the packet to be logged at the specified level. Note that if the <b>ACTION<\/b> involves destination network address translation (DNAT, REDIRECT, etc.) then the packet is logged <b>before<\/b> the destination address is rewritten.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>If the <b>ACTION<\/b> names an <i>action<\/i> declared in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212actions<\/font><\/b><\/big> <font color=\"#000000\">[3] <big>(5) or in \/usr\/share\/shorewall\/actions.std then:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 If the log level is followed by &#8220;!&#8217; then all rules in the action are logged at the log level.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 If the log level is not followed by &#8220;!&#8221; then only those rules in the action that do not specify logging are logged at the specified level.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The special log level <b>none!<\/b> suppresses logging by the action.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>You may also specify <b>ULOG<\/b> (IPv4 only) or <b>NFLOG<\/b> (must be in upper case) as a log level.This will log to the ULOG or NFLOG target for routing to a separate log through use of ulogd (<\/big><\/font><big><b><font color=\"#0000FF\">shorewall\u2212logging(5)<\/font><\/b><\/big> <font color=\"#000000\">[7] <big>).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Actions specifying logging may be followed by a log tag (a string of alphanumeric characters) which is appended to the string generated by the LOGPREFIX (in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b><\/big> <font color=\"#000000\">[2] <big>(5)).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Example: ACCEPT:info:ftp would include &#8216;ftp &#8216; at the end of the log prefix generated by the LOGPREFIX setting.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>SOURCE \u2212<\/b> <i>source\u2212spec<\/i><b>[,&#8230;]<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big>Source hosts to which the rule applies.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>source\u2212spec<\/i> is one of the following:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i><b>[,&#8230;[+]]<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>The name of a zone defined in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212zones<\/font><\/b><\/big> <font color=\"#000000\">[4] <big>(5). When only the zone name is specified, the packet source may be any host in that zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>zone may also be one of the following:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>all[+]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big><b>all<\/b>, without the &#8220;\u2212&#8221; means &#8220;All Zones, including the firewall zone&#8221;. Normally all omits intra\u2212zone traffic, but intra\u2212zone traffic can be included specifying &#8220;+&#8221;.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>any[+]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big><b>any<\/b> is equivalent to <b>all<\/b> when there are no nested zones. When there are nested zones, <b>any<\/b> only refers to top\u2212level zones (those with no parent zones). Note that <b>any<\/b> excludes all vserver zones, since those zones are nested within the firewall zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>none<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big>When <b>none<\/b> is used either in the <b>SOURCE<\/b> or <b>DEST<\/b> column, the rule is ignored.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Similar to with <b>all<\/b> and <b>any<\/b>, intra\u2212zone traffic is normally excluded when multiple zones are listed. Intra\u2212zone traffic may be included by following the list with a plus sign (&#8220;+&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>all<\/b> and <b>any<\/b> may be followed by an exclamation point (&#8220;!&#8221;) and a comma\u2212separated list of zone names to be omitted.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:[!]<i>interface<\/i><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>When this form is used, <i>interface<\/i> must be the name of an interface associated with the named <i>zone<\/i> in either<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212interfaces<\/font><\/b><\/big> <font color=\"#000000\">[8] <big>(5) or<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212hosts<\/font><\/b><\/big> <font color=\"#000000\">[9] <big>(5). Only packets from hosts in the <i>zone<\/i> that arrive through the named interface will match the rule.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorweall 5.2.1, the <i>interface<\/i> may be preceded with &#8216;!&#8217; which matches all interfaces associated with the zone except the one specified.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:<i>address<\/i>[,&#8230;]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>where address can be:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 A host or network IP address. A network address may be followed by exclusion (see<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212exclusion<\/font><\/b><\/big> <font color=\"#000000\">[10] <big>(5)).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 An address range, specified using the syntax <i>lowaddress<\/i>\u2212<i>highaddress<\/i>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 +<i>ipset<\/i> where <i>ipset<\/i> is the name of an ipset and must be preceded by a plus sign (&#8220;+&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 A MAC address in Shorewall format (preceded by a tilde (&#8220;~&#8221;) and with the hex byte values separated by dashes (e.g., &#8220;~00\u22120a\u2212f6\u221204\u22129c\u22127d&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 ^<i>country\u2212code<\/i> where country\u2212code is a two\u2212character ISO\u22123661 country code preceded by a caret (&#8220;^&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 ^<i>country\u2212code\u2212list<\/i> where <i>country\u2212code\u2212list<\/i> is a comma\u2212separated list of up to 15 ISO\u22123661 country codes enclosed in square brackets (&#8220;[&#8230;]&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The primary IP address of a firewall interface can be specified by an ampersand (&#8216;&#038;&#8217;) followed by the logical name of the interface as found in the INTERFACE column of<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212interfaces<\/font><\/b><\/big> <font color=\"#000000\">[8] <big>(5).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:<i>interface<\/i>:<i>address<\/i>[,&#8230;]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form combines the preceding two and requires that both the incoming interface and source address match.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:<i>exclusion<\/i><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form matches if the host IP address does not match any of the entries in the exclusion (see<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212exclusion<\/font><\/b><\/big> <font color=\"#000000\">[10] <big>(5)).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:<i>interface<\/i>:<i>exclusion<\/i><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form matches packets from the named <i>zone<\/i> entering through the specified <i>interface<\/i> where the source address does not match any entry in the <i>exclusion<\/i>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 5.1.0, multiple <i>source\u2212spec<\/i>s may be listed, provided that extended forms of the source\u2212spec are used: <i>zone<\/i>\ud83d\ude41<i>interface<\/i>)<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>\ud83d\ude41<i>address<\/i>[,&#8230;])<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>zone:(interface:address[,&#8230;])<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>\ud83d\ude41<i>exclusion<\/i>)<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>\ud83d\ude41<i>interface<\/i>:<i>exclusion<\/i>) Examples:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>dmz:192.168.2.2<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Host 192.168.2.2 in the DMZ<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:155.186.235.0\/24<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Subnet 155.186.235.0\/24 on the Internet<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:192.168.1.1,192.168.1.2<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 192.168.1.1 and 192.168.1.2 in the local zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:~00\u2212A0\u2212C9\u221215\u221239\u221278<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Host in the local zone with MAC address 00:A0:C9:15:39:78.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:192.0.2.11\u2212192.0.2.17<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 192.0.2.11\u2212192.0.2.17 in the net zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:!192.0.2.11\u2212192.0.2.17<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>All hosts in the net zone except for 192.0.2.11\u2212192.0.2.17.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:155.186.235.0\/24!155.186.235.16\/28<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Subnet 155.186.235.0\/24 on the Internet except for 155.186.235.16\/28<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>$FW:&#038;eth0<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>The primary IP address of eth0 in the firewall zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc,dmz<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Both the <b>loc<\/b> and <b>dmz<\/b> zones.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>all!dmz<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>All but the <b>dmz<\/b> zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>all+!$FW<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>All but the firewall zone and applies to intrazone traffic.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:^CN<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>China.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:(eth1:1.2.3.4,2.3.4.5),dmz:(eth2:5.6.7.8,9.10.11.12),net<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 1.2.3.4 and 2.3.4.5 in the loc zone when the packet arrives through eth1 plus hosts 5.6.7.8 and 9.10.11.12 in the dmz zone when the packet arrives through eth2 plus all of the net zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>dmz:[2002:ce7c:2b4:1::2]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Host 2002:ce7c:92b4:1::2 in the DMZ<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:2001:4d48:ad51:24::\/64<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Subnet 2001:4d48:ad51:24::\/64 on the Internet<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:[2002:cec792b4:1::2],[2002:cec792b4:1::44]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 2002:cec792b4:1::2 and 2002:cec792b4:1::44 in the local zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:~00\u2212A0\u2212C9\u221215\u221239\u221278<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Host in the local zone with MAC address 00:A0:C9:15:39:78.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:[2001:4d48:ad51:24::]\/64![2001:4d48:ad51:24:6::]\/80<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Subnet 2001:4d48:ad51:24::\/64 on the Internet except for 2001:4d48:ad51:24:6::\/80.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>DEST \u2212<\/b> <i>dest\u2212spec<\/i><b>[,&#8230;]<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big>Destination hosts to which the rule applies.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>dest\u2212spec<\/i> is one of the following:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i><b>[,&#8230;[+]]<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>The name of a zone defined in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212zones<\/font><\/b><\/big> <font color=\"#000000\">[4] <big>(5). When only the zone name is specified, the packet destination may be any host in that zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>zone may also be one of the following:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>all[+]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big><b>all<\/b>, without the &#8220;\u2212&#8221; means &#8220;All Zones, including the firewall zone&#8221;. Normally all omits intra\u2212zone traffic, but intra\u2212zone traffic can be included specifying &#8220;+&#8221;.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>any[+]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big><b>any<\/b> is equivalent to <b>all<\/b> when there are no nested zones. When there are nested zones, <b>any<\/b> only refers to top\u2212level zones (those with no parent zones). Note that <b>any<\/b> excludes all vserver zones, since those zones are nested within the firewall zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>none<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%;\"><big><font color=\"#000000\"><big>When <b>none<\/b> is used either in the <b>SOURCE<\/b> or <b>DEST<\/b> column, the rule is ignored.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Similar to with <b>all<\/b> and <b>any<\/b>, intra\u2212zone traffic is normally excluded when multiple zones are listed. Intra\u2212zone traffic may be included by following the list with a plus sign (&#8220;+&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>all<\/b> and <b>any<\/b> may be followed by an exclamation point (&#8220;!&#8221;) and a comma\u2212separated list of zone names to be omitted.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:[!]<i>interface<\/i><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>When this form is used, <i>interface<\/i> must be the name of an interface associated with the named <i>zone<\/i> in either<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212interfaces<\/font><\/b><\/big> <font color=\"#000000\">[8] <big>(5) or<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212hosts<\/font><\/b><\/big> <font color=\"#000000\">[11] <big>(5). Only packets to hosts in the <i>zone<\/i> that are sent through the named interface will match the rule.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorweall 5.2.1, the <i>interface<\/i> may be preceded with &#8216;!&#8217; which matches all interfaces associated with the zone except the one specified.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:<i>address<\/i>[,&#8230;]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>where address can be:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 A host or network IP address. A network address may be followed by exclusion (see<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212exclusion<\/font><\/b><\/big> <font color=\"#000000\">[10] <big>(5)).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 An address range, specified using the syntax <i>lowaddress<\/i>\u2212<i>highaddress<\/i>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 +<i>ipset<\/i> where <i>ipset<\/i> is the name of an ipset and must be preceded by a plus sign (&#8220;+&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 ^<i>country\u2212code<\/i> where country\u2212code is a two\u2212character ISO\u22123661 country code preceded by a caret (&#8220;^&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 ^<i>country\u2212code\u2212list<\/i> where <i>country\u2212code\u2212list<\/i> is a comma\u2212separated list of up to 15 ISO\u22123661 country codes enclosed in square brackets (&#8220;[&#8230;]&#8221;).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The primary IP address of a firewall interface can be specified by an ampersand (&#8216;&#038;&#8217;) followed by the logical name of the interface as found in the INTERFACE column of<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212interfaces<\/font><\/b><\/big> <font color=\"#000000\">[8] <big>(5).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:[!]<i>interface<\/i>:<i>address<\/i>[,&#8230;]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form combines the preceding two and requires that both the outgoing interface and destinationaddress match.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorweall 5.2.1, the <i>interface<\/i> may be preceded with &#8216;!&#8217; which matches all interfaces associated with the zone except the one specified.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:<i>exclusion<\/i><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form matches if the host IP address does not match any of the entries in the exclusion (see<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212exclusion<\/font><\/b><\/big> <font color=\"#000000\">[10] <big>(5)).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>:[!]<i>interface<\/i>:<i>exclusion<\/i><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form matches packets to the named <i>zone<\/i> leaving through the specified <i>interface<\/i> where the destination address does not match any entry in the <i>exclusion<\/i>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorweall 5.2.1, the <i>interface<\/i> may be preceded with &#8216;!&#8217; which matches all interfaces associated with the zone except the one specified.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>[<i>zone<\/i>]:[<i>server\u2212IP<\/i>][:<i>port\u2212or\u2212port\u2212range<\/i>[:random]]<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>This form applies when the ACTION is DNAT[\u2212] or REDIRECT[\u2212]. The zone may be omitted in REDIRECT rules ($FW is assumed) and must be omitted in DNAT\u2212, REDIRECT\u2212 and NONAT rules.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>server\u2212IP<\/i> is not allowed in REDIRECT rules and may be omitted in DNAT[\u2212] rules provided that <i>port\u2212or\u2212port\u2212range<\/i> is included.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The IP address of the server to which the packet is to be sent.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 A range of IP address with the low and high address separated by a dash (:&#8221;\u2212&#8221;). Connections are distributed among the IP addresses in the range.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>If <i>server\u2212IP<\/i> is omitted in a DNAT[\u2212] rule, only the destination port number is modified by the rule.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>port\u2212or\u2212port\u2212range may be:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 An integer port number in the range 1 \u2212 65535.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 The name of a service from \/etc\/services.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:29%; margin-top: 1em\"><big><font color=\"#000000\"><big>\u2022 A port range with the low and high integer port numbers separated by a dash (&#8220;\u2212&#8221;). Connections are distributed among the ports in the range.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>If <b>random<\/b> is specified, port mapping will be randomized.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>If the DEST <i>zone<\/i> is a bport zone, then either:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>1. the SOURCE must be <b>all[+]<\/b>, or<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>2. the SOURCE <i>zone<\/i> must be another bport zone associated with the same bridge, or<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big>3. the SOURCE <i>zone<\/i> must be an ipv4 zone that is associated with only the same bridge.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 5.1.0, multiple <i>dest\u2212spec<\/i>s may be listed, provided that extended forms of the source\u2212spec are used: <i>zone<\/i>\ud83d\ude41<i>interface<\/i>)<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>\ud83d\ude41<i>address<\/i>[,&#8230;])<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>zone:(interface:address[,&#8230;])<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>\ud83d\ude41<i>exclusion<\/i>)<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><i>zone<\/i>\ud83d\ude41<i>interface<\/i>:<i>exclusion<\/i>) Multiple <i>dest\u2212spec<\/i>s are not permitted in DNAT[\u2212] and REDIRECT[\u2212] rules.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Examples:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>dmz:192.168.2.2<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Host 192.168.2.2 in the DMZ<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:155.186.235.0\/24<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Subnet 155.186.235.0\/24 on the Internet<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:192.168.1.1,192.168.1.2<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 192.168.1.1 and 192.168.1.2 in the local zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:192.0.2.11\u2212192.0.2.17<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 192.0.2.11\u2212192.0.2.17 in the net zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:!192.0.2.11\u2212192.0.2.17<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>All hosts in the net zone except for 192.0.2.11\u2212192.0.2.17.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:155.186.235.0\/24!155.186.235.16\/28<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Subnet 155.186.235.0\/24 on the Internet except for 155.186.235.16\/28<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>$FW:&#038;eth0<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>The primary IP address of eth0 in the firewall zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc,dmz<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Both the <b>loc<\/b> and <b>dmz<\/b> zones.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>all!dmz<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>All but the <b>dmz<\/b> zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>net:^CN<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>China.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>dmz:192.168.10.4:25<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Port 25 on server 192.168.10.4 in the dmz zone (DNAT rule).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>loc:(eth1:1.2.3.4,2.3.4.5),dmz:(eth2:5.6.7.8,9.10.11.12),net<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><font color=\"#000000\"><big>Hosts 1.2.3.4 and 2.3.4.5 in the loc zone when the packet arrives through eth1 plus hosts 5.6.7.8 and 9.10.11.12 in the dmz zone when the packet arrives through eth2 plus all of the net zone.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>PROTO<\/b>\u2212 {<b>\u2212<\/b>|<b>tcp:[!]syn<\/b>|<b>ipp2p<\/b>|<b>ipp2p:udp<\/b>|<b>ipp2p:all<\/b>|<i>protocol\u2212number<\/i>|<i>protocol\u2212name<\/i>|<b>all}<\/b><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big>Optional Protocol \u2212 <b>ipp2p<\/b>* requires ipp2p match support in your kernel and iptables. <b>tcp:syn<\/b> implies <b>tcp<\/b> plus the SYN flag must be set and the RST, ACK and FIN flags must be reset. Beginning with Shorewall 5.1.3, you may also specify <b>tcp:!syn<\/b>, which matches if SYN is not set or if RST, ACK or FIN is set.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 4.4.19, this column can contain a comma\u2212separated list of protocol\u2212numbers and\/or protocol names.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>DPORT<\/b> \u2212 {<b>\u2212<\/b>|<i>port\u2212name\u2212number\u2212or\u2212range<\/i>[<b>,<\/b><i>port\u2212name\u2212number\u2212or\u2212range<\/i>]&#8230;|+<i>ipset<\/i>}<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big>Optional destination Ports. A comma\u2212separated list of Port names (from services(5)), port numbers or port ranges; if the protocol is <b>icmp<\/b>, this column is interpreted as the destination icmp\u2212type(s). ICMP types may be specified as a numeric type, a numeric type and code separated by a slash (e.g., 3\/4), or a typename. See<\/big><\/font> <big><b><font color=\"#0000FF\">https:\/\/shorewall.org\/configuration_file_basics.htm#ICMP<\/font><\/b><\/big> <font color=\"#000000\">[12] <big>. Note that prior to Shorewall 4.4.19, only a single ICMP type may be listed.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>If the protocol is <b>ipp2p<\/b>, this column is interpreted as an ipp2p option without the leading &#8220;\u2212\u2212&#8221; (example <b>bit<\/b> for bit\u2212torrent). If no port is given, <b>ipp2p<\/b> is assumed.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>A port range is expressed as <i>lowport<\/i>:<i>highport<\/i>.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>This column is ignored if <b>PROTO<\/b> = <b>all<\/b> but must be entered if any of the following columns are supplied. In that case, it is suggested that this field contain a dash (<b>\u2212<\/b>).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>If your kernel contains multi\u2212port match support, then only a single Netfilter rule will be generated if in this list and the <b>SPORT<\/b> list below:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>1. There are 15 or less ports listed.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>2. No port ranges are included or your kernel and iptables contain extended multi\u2212port match support.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 4.6.0, an <i>ipset<\/i> name can be specified in this column. This is intended to be used with bitmap:port ipsets.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>This column was formerly labelled DEST PORT(S).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><font color=\"#000000\"><big><b>SPORT<\/b> \u2212 {<b>\u2212<\/b>|<i>port\u2212name\u2212number\u2212or\u2212range<\/i>[<b>,<\/b><i>port\u2212name\u2212number\u2212or\u2212range<\/i>]&#8230;|+<i>ipset<\/i>}<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big>Optional port(s) used by the client. If omitted, any source port is acceptable. Specified as a comma\u2212 separated list of port names, port numbers or port ranges.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 4.5.15, you may place &#8216;=&#8217; in this column, provided that the DPORT column is non\u2212empty. This causes the rule to match when either the source port or the destination port in a packet matches one of the ports specified in DEST PORTS(S). Use of &#8216;=&#8217; requires multi\u2212port match in your iptables and kernel.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><font color=\"#000000\"><big><b><big>Warning<\/big><\/b> <br \/> Unless you really understand IP, you should leave this column empty or place a dash (<b>\u2212<\/b>) in the column. Most people who try to use this column get it wrong.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big>If you don&#8217;t want to restrict client ports but need to specify an <b>ORIGDEST<\/b> in the next column, then place &#8220;\u2212&#8221; in this column.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>If your kernel contains multi\u2212port match support, then only a single Netfilter rule will be generated if in this list and the <b>DPORT<\/b> list above:<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>1. There are 15 or less ports listed.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>2. No port ranges are included or your kernel and iptables contain extended multi\u2212port match support.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>Beginning with Shorewall 4.6.0, an <i>ipset<\/i> name can be specified in this column. This is intended to be used with bitmap:port ipsets.<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big>This column was formerly labelled SOURCE PORT(S).<\/big><\/font><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><font color=\"#000000\"><big><b><big>ORIGDEST<\/big><\/b> <big>\u2212 [<b>\u2212<\/b>|<i>address<\/i>[,<i>address<\/i>]&#8230;[<i>exclusion<\/i>]|<i>exclusion<\/i>]<\/big><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><font color=\"#000000\"><big><big>Optional. If ACTION is <b>DNAT<\/b>[<b>\u2212<\/b>] or <b>REDIRECT<\/b>[<b>\u2212<\/b>] then if this column is included and is different from the IP address given in the <b>DEST<\/b> column, then connections destined for that address will be forwarded to the IP and port specified in the <b>DEST<\/b> column.<\/big><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><big>A comma\u2212separated list of addresses may also be used. This is most useful with the <b>REDIRECT<\/b> target where you want to redirect traffic destined for particular set of hosts. Finally, if the list of addresses begins with &#8220;!&#8221; (<i>exclusion<\/i>) then the rule will be followed only if the original destination address in the connection request does not match any of the addresses listed.<\/big><\/big><\/font><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><font color=\"#000000\"><big><big>Beginning with Shorewall 4.4.17, the primary IP address of a firewall interface can be specified by an ampersand (&#8216;&#038;&#8217;) followed by the logical name of the interface as found in the INTERFACE column of<\/big><\/big><\/font> <big><big><b><font color=\"#0000FF\">shorewall\u2212interfaces<\/font><\/b><\/big> <font color=\"#000000\">[8] <big>(5).<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>For other actions, this column may be included and may contain one or more addresses (host or network) separated by commas. Address ranges are not allowed. When this column is supplied, rules are generated that require that the original destination address matches one of the listed addresses. This feature is most useful when you want to generate a filter rule that corresponds to a <b>DNAT\u2212<\/b> or <b>REDIRECT\u2212<\/b> rule. In this usage, the list of addresses should not begin with &#8220;!&#8221;.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>It is also possible to specify a set of addresses then exclude part of those addresses. For example, <b>192.168.1.0\/24!192.168.1.16\/28<\/b> specifies the addresses 192.168.1.0\u2212182.168.1.15 and 192.168.1.32\u2212192.168.1.255. See<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212exclusion<\/font><\/b><\/big> <font color=\"#000000\">[10] <big>(5).<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>See<\/big><\/font> <big><b><font color=\"#0000FF\">https:\/\/shorewall.org\/PortKnocking.html<\/font><\/b><\/big> <font color=\"#000000\">[13] <big>for an example of using an entry in this column with a user\u2212defined action rule.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>This column was formerly labelled ORIGINAL DEST.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>RATE<\/b> \u2212 <i>limit<\/i><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>where <i>limit<\/i> is one of:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>[<b>\u2212<\/b>|[{<b>s<\/b>|<b>d<\/b>}[\/<i>vlsm<\/i>]:[<i>name<\/i>[(<i>ht\u2212buckets<\/i>,<i>ht\u2212max<\/i>)]:]<i>rate<\/i><b>\/<\/b>{<b>sec<\/b>|<b>min<\/b>|<b>hour<\/b>|<b>day<\/b>}[:<i>burst<\/i>] <br \/> [<b>s<\/b>[\/<i>vlsm1<\/i>]:][<i>name<\/i>1[(<i>ht\u2212buckets1<\/i>,<i>ht\u2212max1<\/i>)]:]<i>rate1<\/i><b>\/<\/b>{<b>sec<\/b>|<b>min<\/b>|<b>hour<\/b>|<b>day<\/b>}[:<i>burst1<\/i>],[<b>d<\/b>[\/<i>vlsm2<\/i>:][<i>name<\/i>2[(<i>ht\u2212buckets2<\/i>,<i>ht\u2212max2<\/i>)]:]<i>rate2<\/i><b>\/<\/b>{<b>sec<\/b>|<b>min<\/b>|<b>hour<\/b>|<b>day<\/b>}[:<i>burst2<\/i>]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You may optionally rate\u2212limit the rule by placing a value in this column:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><i>rate*<\/i> is the number of connections per interval (<b>sec<\/b> or <b>min<\/b>) and <i>burst<\/i>* is the largest burst permitted. If no <i>burst<\/i> is given, a value of 5 is assumed. There may be no no white\u2212space embedded in the specification.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example: <b>10\/sec:20<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>When <b>s:<\/b> or <b>d:<\/b> is specified, the rate applies per source IP address or per destination IP address respectively. The <i>name<\/i>s may be chosen by the user and specify a hash table to be used to count matching connections. If not given, the name <b>shorewallN<\/b> (where N is a unique integer) is assumed. Where more than one rule or POLICY specifies the same name, the connections counts for the rules are aggregated and the individual rates apply to the aggregated count. Beginning with Shorewall 5.2.1, the <b>s<\/b> or <b>d<\/b> may be followed by a slash (&#8220;\/&#8221;) and an integer <i>vlsm<\/i>. When a <i>vlsm<\/i> is specified, all source or destination addresses encountered will be grouped according to the given prefix length and the so\u2212created subnet will be subject to the rate limit.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example: <b>s\/24::10\/sec<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Beginning with Shorewall 4.6.5, two <i>limit<\/i>s may be specified, separated by a comma. In this case, the first limit (<i>name1<\/i>, <i>rate1<\/i>, burst1) specifies the per\u2212source IP limit and the second limit specifies the per\u2212destination IP limit.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example: <b>client:10\/sec:20,:60\/sec:100<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>In this example, the &#8216;client&#8217; hash table will be used to enforce the per\u2212source limit and the compiler will pick a unique name for the hash table that tracks the per\u2212destination limit.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Beginning with Shorewall 5.2.1, the table name, if any, may be followed by two integers separated by commas and enclosed in parentheses. The first integer (<i>ht\u2212buckets<\/i>) specifies the number of buckets in the generated hash table. The second integer (<i>ht\u2212max<\/i>) specifies the maximum number of entries in the hash table.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example: <b>s:netfw(1024,65536):10\/sec<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>This column was formerly labelled RATE LIMIT.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>USER<\/b> \u2212 [<b>!<\/b>][<i>user\u2212name\u2212or\u2212number<\/i>][<b>:<\/b><i>group\u2212name\u2212or\u2212number<\/i>][,&#8230;]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>This optional column may only be non\u2212empty if the SOURCE is the firewall itself.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>When this column is non\u2212empty, the rule applies only if the program generating the output is running under the effective <i>user<\/i> and\/or <i>group<\/i> specified (or is NOT running under that id if &#8220;!&#8221; is given).<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Beginning with Shorewall 4.5.8, multiple user or group names\/ids separated by commas may be specified.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Examples:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>joe<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>program must be run by joe<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>:kids<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>program must be run by a member of the &#8216;kids&#8217; group<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>!:kids<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>program must not be run by a member of the &#8216;kids&#8217; group<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>2001\u22122099<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>UIDs 2001 through 2099 (Shorewall 4.5.6 and later)<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>This column was formerly labelled USER\/GROUP.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>MARK<\/b> \u2212 [<b>!<\/b>]<i>value<\/i>[\/<i>mask<\/i>][<b>:C<\/b>]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Defines a test on the existing packet or connection mark. The rule will match only if the test returns true.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>If you don&#8217;t want to define a test but need to specify anything in the following columns, place a &#8220;\u2212&#8221; in this field.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>!<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Inverts the test (not equal)<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><i>value<\/i><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Value of the packet or connection mark.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><i>mask<\/i><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>A mask to be applied to the mark before testing.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>:C<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Designates a connection mark. If omitted, the packet mark&#8217;s value is tested.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>CONNLIMIT<\/b> \u2212 [d:][<b>!<\/b>]<i>limit<\/i>[:<i>mask<\/i>]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>May be used to limit the number of simultaneous connections to\/from each individual host or network to <i>limit<\/i> connections. Requires connlimit match in your kernel and iptables. While the limit is only checked on rules specifying CONNLIMIT, the number of current connections is calculated over all current connections from the SOURCE or DESTINATION host. By default, limiting is done by SOURCE host or net, but if the specification begins with <b>d:<\/b>, then limiting will be donw by destination host or net.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>By default, the limit is applied to each host but can be made to apply to networks of hosts by specifying a <i>mask<\/i>. The <i>mask<\/i> specifies the width of a VLSM mask to be applied to the source address; the number of current connections is then taken over all hosts in the subnet <i>source\u2212address<\/i>\/<i>mask<\/i>. When <b>!<\/b> is specified, the rule matches when the number of connection exceeds the <i>limit<\/i>.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>TIME<\/b> \u2212 <i>timeelement<\/i>[&#038;<i>timeelement<\/i>&#8230;]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>May be used to limit the rule to a particular time period each day, to particular days of the week or month, or to a range defined by dates and times. Requires time match support in your kernel and iptables.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><i>timeelement<\/i> may be:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>timestart=<i>hh<\/i>:<i>mm<\/i>[:<i>ss<\/i>]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Defines the starting time of day.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>timestop=<i>hh<\/i>:<i>mm<\/i>[:<i>ss<\/i>]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Defines the ending time of day.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>contiguous<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Added in Shoreawll 5.0.12. When <b>timestop<\/b> is smaller than <b>timestart<\/b> value, match this as a single time period instead of distinct intervals.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>utc<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Times are expressed in Greenwich Mean Time.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>localtz<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Deprecated by the Netfilter team in favor of <b>kerneltz<\/b>. Times are expressed in Local Civil Time (default).<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>kerneltz<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Added in Shorewall 4.5.2. Times are expressed in Local Kernel Time (requires iptables 1.4.12 or later).<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>weekdays=ddd[,ddd]&#8230;<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>where <i>ddd<\/i> is one of <b>Mon<\/b>, <b>Tue<\/b>, <b>Wed<\/b>, <b>Thu<\/b>, <b>Fri<\/b>, <b>Sat<\/b> or <b>Sun<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>monthdays=dd[,dd],&#8230;<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>where <i>dd<\/i> is an ordinal day of the month<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>datestart=<i>yyyy<\/i>[\u2212<i>mm<\/i>[\u2212<i>dd<\/i>[<b>T<\/b><i>hh<\/i>[:<i>mm<\/i>[:<i>ss<\/i>]]]]]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Defines the starting date and time.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>datestop=<i>yyyy<\/i>[\u2212<i>mm<\/i>[\u2212<i>dd<\/i>[<b>T<\/b><i>hh<\/i>[:<i>mm<\/i>[:<i>ss<\/i>]]]]]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Defines the ending date and time.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>HEADERS \u2212 [!][any:|exactly:]<\/b><i>header\u2212list<\/i> (Optional \u2212 Added in Shorewall 4.4.15)<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>This column is only used in IPv6. In IPv4, supply &#8220;\u2212&#8221; in this column if you with to place a value in one of the following columns.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>The <i>header\u2212list<\/i> consists of a comma\u2212separated list of headers from the following list.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>auth<\/b>, <b>ah<\/b>, or <b>51<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Authentication Headers extension header.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>esp<\/b>, or <b>50<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Encrypted Security Payload extension header.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>hop<\/b>, <b>hop\u2212by\u2212hop<\/b> or <b>0<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Hop\u2212by\u2212hop options extension header.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>route<\/b>, <b>ipv6\u2212route<\/b> or <b>43<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>IPv6 Route extension header.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>frag<\/b>, <b>ipv6\u2212frag<\/b> or <b>44<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>IPv6 fragmentation extension header.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>none<\/b>, <b>ipv6\u2212nonxt<\/b> or <b>59<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>No next header<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>proto<\/b>, <b>protocol<\/b> or <b>255<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big>Any protocol header.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>If <b>any:<\/b> is specified, the rule will match if any of the listed headers are present. If <b>exactly:<\/b> is specified, the will match packets that exactly include all specified headers. If neither is given, <b>any:<\/b> is assumed.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>If <b>!<\/b> is entered, the rule will match those packets which would not be matched when <b>!<\/b> is omitted.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>SWITCH \u2212 [!]<\/b><i>switch\u2212name<\/i><b>[={0|1}]<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Added in Shorewall 4.4.24 and allows enabling and disabling the rule without requiring <b>shorewall reload<\/b>.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>The rule is enabled if the value stored in \/proc\/net\/nf_condition\/<i>switch\u2212name<\/i> is 1. The rule is disabled if that file contains 0 (the default). If &#8216;!&#8217; is supplied, the test is inverted such that the rule is enabled if the file contains 0.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Within the <i>switch\u2212name<\/i>, &#8216;@0&#8217; and &#8216;@{0}&#8217; are replaced by the name of the chain to which the rule is a added. The <i>switch\u2212name<\/i> (after &#8216;@&#8230;&#8217; expansion) must begin with a letter and be composed of letters, decimal digits, underscores or hyphens. Switch names must be 30 characters or less in length.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Switches are normally <b>off<\/b>. To turn a switch <b>on<\/b>:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big><b>echo 1 > <br \/> \/proc\/net\/nf_condition\/<\/b><i>switch\u2212name<\/i><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>To turn it <b>off<\/b> again:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big><b>echo 0 > <br \/> \/proc\/net\/nf_condition\/<\/b><i>switch\u2212name<\/i><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Switch settings are retained over <b>shorewall reload<\/b>.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Beginning with Shorewall 4.5.10, when the <i>switch\u2212name<\/i> is followed by <b>=0<\/b> or <b>=1<\/b>, then the switch is initialized to off or on respectively by the <b>start<\/b> command. Other commands do not affect the switch setting.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big><b>HELPER<\/b> \u2212 [helper]<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Added in Shorewall 4.5.7.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>In the NEW section, causes the named conntrack <i>helper<\/i> to be associated with this connection; the contents of this column are ignored unless ACTION is ACCEPT*, DNAT* or REDIRECT*.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>In the RELATED section, will only match if the related connection has the named <i>helper<\/i> associated with it.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>The <i>helper<\/i> may be one of:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%;\"><big><big><font color=\"#000000\"><big><b>amanda <br \/> ftp <br \/> irc <br \/> netbios\u2212ns <br \/> pptp <br \/> Q.931 <br \/> RAS <br \/> sane <br \/> sip <br \/> snmp <br \/> tftp<\/b><\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>If the HELPERS option is specified in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall.conf<\/font><\/b><\/big> <font color=\"#000000\">[2] <big>(5), then any module specified in this column must be listed in the HELPERS setting.<\/big><\/font><\/big><\/big><\/p>\n<h2>EXAMPLES <a name=\"EXAMPLES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 1:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Accept SMTP requests from the DMZ to the internet<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> ACCEPT dmz net tcp smtp<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 2:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Forward all ssh and http connection requests from the internet to local system 192.168.1.3<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> DNAT net loc:192.168.1.3 tcp ssh,http<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 3:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Forward all http connection requests from the internet to local system 192.168.1.3 with a limit of 3 per second and a maximum burst of 10<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST RATE <br \/> DNAT net loc:192.168.1.3 tcp http \u2212 \u2212 3\/sec:10<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 4:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Redirect all locally\u2212originating www connection requests to port 3128 on the firewall (Squid running on the firewall system) except when the destination address is 192.168.2.2<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> REDIRECT loc 3128 tcp www \u2212 !192.168.2.2<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 5:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>All http requests from the internet to address 130.252.100.69 are to be forwarded to 192.168.1.3<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> DNAT net loc:192.168.1.3 tcp 80 \u2212 130.252.100.69<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 6:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You want to accept SSH connections to your firewall only from internet IP addresses 130.252.100.69 and 130.252.100.70<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> ACCEPT net:130.252.100.69,130.252.100.70  <br \/> $FW tcp 22<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 7:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You wish to accept connections from the internet to your firewall on port 2222 and you want to forward them to local system 192.168.1.3, port 22<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> DNAT net loc:192.168.1.3:22 tcp 2222<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 8:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You want to redirect connection requests to port 80 randomly to the port range 81\u221290.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> REDIRECT net $FW::81\u221290:random tcp www<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 9:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Shorewall does not impose as much structure on the Netfilter rules in the &#8216;nat&#8217; table as it does on those in the filter table. As a consequence, when using Shorewall versions before 4.1.4, care must be exercised when using DNAT and REDIRECT rules with zones defined with wildcard interfaces (those ending with &#8216;+&#8217;. Here is an example:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><big><b><font color=\"#0000FF\">shorewall\u2212zones<\/font><\/b><\/big> <font color=\"#000000\">[4] <big>(5):<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ZONE TYPE OPTIONS <br \/> fw firewall <br \/> net ipv4 <br \/> dmz ipv4 <br \/> loc ipv4<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><big><b><font color=\"#0000FF\">shorewall\u2212interfaces<\/font><\/b><\/big> <font color=\"#000000\">[8] <big>(5):<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ZONE INTERFACE BROADCAST OPTIONS <br \/> net ppp0 <br \/> loc eth1 detect <br \/> dmz eth2 detect <br \/> \u2212 ppp+ # Addresses are assigned from 192.168.3.0\/24<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><big><b><font color=\"#0000FF\">shorewall\u2212host<\/font><\/b><\/big> <font color=\"#000000\">[11] <big>(5):<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ZONE HOST(S) OPTIONS <br \/> loc ppp+:192.168.3.0\/24<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>rules:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT <br \/> REDIRECT loc 3128 tcp 80<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Note that it would have been tempting to simply define the loc zone entirely in shorewall\u2212interfaces(8):<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#******************* INCORRECT bodies manpages.csv script_extrae_body.sh script.sh usr <br \/> #ZONE INTERFACE BROADCAST OPTIONS <br \/> net ppp0 <br \/> loc eth1 detect <br \/> loc ppp+ <br \/> dmz eth2<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>This would have made it impossible to run a internet\u2212accessible web server in the DMZ because all traffic entering ppp+ interfaces would have been redirected to port 3128 on the firewall and there would have been no net\u2212>fw ACCEPT rule for that traffic.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 10:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Add the tuple (source IP, dest port, dest IP) of an incoming SSH connection to the ipset S:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT <br \/> ADD(+S:dst,src,dst) net fw tcp 22<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 11:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You wish to limit SSH connections from remote systems to 1\/min with a burst of three (to allow for limited retry):<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST RATE <br \/> SSH(ACCEPT) net all \u2212 \u2212 \u2212 \u2212 s:1\/min:3<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 12:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Forward port 80 to dmz host $BACKUP if switch &#8216;primary_down&#8217; is on.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST RATE USER MARK CONNLIMIT TIME HEADERS SWITCH <br \/> DNAT net dmz:$BACKUP tcp 80 \u2212 \u2212 \u2212 \u2212 \u2212 \u2212 \u2212 \u2212 primary_down<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 13:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>Drop all email from the <i>Anonymous Proxy<\/i> and <i>Satellite Provider<\/i> address ranges:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT <br \/> DROP net:^A1,A2 fw tcp 25<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 14:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You want to generate your own rule involving iptables targets and matches not supported by Shorewall.<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT <br \/> INLINE $FW net ; \u2212p 6 \u2212m mickey\u2212mouse \u2212\u2212name test \u2212m set \u2212\u2212match\u2212set set1 src \u2212m mickey\u2212mouse \u2212\u2212name test2 \u2212j SECCTX \u2212\u2212name test3<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>The above will generate the following iptables\u2212restore input:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>\u2212A fw2net \u2212p 6 \u2212m mickey\u2212mouse \u2212\u2212name test \u2212m set \u2212\u2212match\u2212set set1 src \u2212m mickey\u2212mouse \u2212\u2212name test2 \u2212j SECCTX \u2212\u2212name test3<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Note that SECCTX must be defined as a builtin action in<\/big><\/font> <big><b><font color=\"#0000FF\">shorewall\u2212actions<\/font><\/b><\/big> <font color=\"#000000\">[3] <big>(5):<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION OPTIONS <br \/> SECCTX builtin<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>Example 15:<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>You want to accept SSH connections to your firewall only from internet IP addresses 2002:ce7c::92b4:1::2 and 2002:ce7c::92b4:1::22<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST <br \/> ACCEPT net:<2002:ce7c::92b4:1::2,2002:ce7c::92b4:1::22>  <br \/> $FW tcp 22<\/big><\/font><\/big><\/big><\/p>\n<h2>FILES <a name=\"FILES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>\/etc\/shorewall\/rules<\/big><\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>\/etc\/shorewall6\/rules<\/big><\/font><\/big><\/big><\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><big><b><font color=\"#0000FF\">shorewall\u2212logging(5)<\/font><\/b><\/big> <font color=\"#000000\">[7]<\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><b><big><font color=\"#0000FF\">https:\/\/shorewall.org\/ipsets.html<\/font><\/big><\/b> <font color=\"#000000\">[14]<\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><b><big><font color=\"#0000FF\">https:\/\/shorewall.org\/configuration_file_basics.htm#Pairs<\/font><\/big><\/b> <font color=\"#000000\">[15]<\/font><\/big><\/big><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall(8)<\/big><\/font><\/big><\/big><\/p>\n<h2>NOTES <a name=\"NOTES\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>1.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"25%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-policy<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"58%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-policy.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>2.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"21%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall.conf<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"62%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall.conf.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>3.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"26%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-actions<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"57%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-actions.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>4.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"23%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-zones<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"60%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-zones.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>5.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"26%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-nesting<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"57%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-nesting.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>6.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"68%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/shorewall_logging.html<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"15%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/shorewall_logging.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>7.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"31%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-logging(5)<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"52%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-logging.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>8.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"31%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-interfaces<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"52%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-interfaces.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>9.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"23%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-hosts<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"60%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall.hosts.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>10.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-exclusion<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-exclusion.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>11.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"23%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>shorewall-hosts<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"60%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/manpages\/shorewall-hosts.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>12.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"83%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/configuration_file_basics.htm#ICMP<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/configuration_file_basics.htm#ICMP<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>13.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"60%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/PortKnocking.html<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"23%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/PortKnocking.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>14.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"51%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/ipsets.html<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"32%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/ipsets.html<\/big><\/font><\/big><\/big><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>15.<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"83%\">\n<p style=\"margin-top: 1em\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/configuration_file_basics.htm#Pairs<\/big><\/font><\/big><\/big><\/p>\n<\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><big><big><font color=\"#000000\"><big>https:\/\/shorewall.org\/configuration_file_basics.htm#Pairs<\/big><\/font><\/big><\/big><\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  rules \u2212 Shorewall rules file <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[959],"tags":[961,1291,1385],"class_list":["post-4377","post","type-post","status-publish","format-standard","hentry","category-5-formatos-de-ficheros","tag-961","tag-man5","tag-shorewall-rules"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/4377","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=4377"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/4377\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=4377"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=4377"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=4377"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}