mirror of
https://gitlab.com/shorewall/code.git
synced 2025-02-16 17:51:16 +01:00
Add ZERO_MARKS option
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
3f8ddb11ab
commit
792b3b696c
@ -897,6 +897,7 @@ sub initialize( $;$$) {
|
|||||||
PAGER => undef ,
|
PAGER => undef ,
|
||||||
MINIUPNPD => undef ,
|
MINIUPNPD => undef ,
|
||||||
VERBOSE_MESSAGES => undef ,
|
VERBOSE_MESSAGES => undef ,
|
||||||
|
ZERO_MARKS => undef ,
|
||||||
#
|
#
|
||||||
# Packet Disposition
|
# Packet Disposition
|
||||||
#
|
#
|
||||||
@ -6292,6 +6293,7 @@ sub get_configuration( $$$$ ) {
|
|||||||
default_yes_no 'DEFER_DNS_RESOLUTION' , 'Yes';
|
default_yes_no 'DEFER_DNS_RESOLUTION' , 'Yes';
|
||||||
default_yes_no 'MINIUPNPD' , '';
|
default_yes_no 'MINIUPNPD' , '';
|
||||||
default_yes_no 'VERBOSE_MESSAGES' , 'Yes';
|
default_yes_no 'VERBOSE_MESSAGES' , 'Yes';
|
||||||
|
default_yes_no 'ZERO_MARKS' , '';
|
||||||
|
|
||||||
$config{IPSET} = '' if supplied $config{IPSET} && $config{IPSET} eq 'ipset';
|
$config{IPSET} = '' if supplied $config{IPSET} && $config{IPSET} eq 'ipset';
|
||||||
|
|
||||||
|
@ -128,7 +128,10 @@ sub setup_route_marking() {
|
|||||||
#
|
#
|
||||||
# Clear the mark -- we have seen cases where the mark is non-zero even in the raw table chains!
|
# Clear the mark -- we have seen cases where the mark is non-zero even in the raw table chains!
|
||||||
#
|
#
|
||||||
add_ijump( $mangle_table->{$_}, j => 'MARK', targetopts => '--set-mark 0' ) for qw/PREROUTING OUTPUT/;
|
|
||||||
|
if ( $config{ZERO_MARKS} ) {
|
||||||
|
add_ijump( $mangle_table->{$_}, j => 'MARK', targetopts => '--set-mark 0' ) for qw/PREROUTING OUTPUT/;
|
||||||
|
}
|
||||||
|
|
||||||
if ( $config{RESTORE_ROUTEMARKS} ) {
|
if ( $config{RESTORE_ROUTEMARKS} ) {
|
||||||
add_ijump $mangle_table->{$_} , j => 'CONNMARK', targetopts => "--restore-mark --mask $mask" for qw/PREROUTING OUTPUT/;
|
add_ijump $mangle_table->{$_} , j => 'CONNMARK', targetopts => "--restore-mark --mask $mask" for qw/PREROUTING OUTPUT/;
|
||||||
|
@ -248,6 +248,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -259,6 +259,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -256,6 +256,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -259,6 +259,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -248,6 +248,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -2947,6 +2947,23 @@ INLINE - - - ;; -j REJECT
|
|||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term><emphasis role="bold">ZERO_MARKS=</emphasis>[<emphasis
|
||||||
|
role="bold">Yes</emphasis>|<emphasis role="bold">No</emphasis>]</term>
|
||||||
|
|
||||||
|
<listitem>
|
||||||
|
<para>Added in Shorewall 5.0.12, this is a workaround for an issue
|
||||||
|
where packet marks are not zeroed by the kernel. It should be set to
|
||||||
|
No (the default) unless you find that incoming packets are being
|
||||||
|
mis-routed for no apparent reasons.</para>
|
||||||
|
|
||||||
|
<caution>
|
||||||
|
<para>Do not set this option to Yes if you have IPSEC software
|
||||||
|
running on the firewall system.</para>
|
||||||
|
</caution>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term><emphasis
|
<term><emphasis
|
||||||
role="bold">ZONE_BITS</emphasis>=[<replaceable>number</replaceable>]</term>
|
role="bold">ZONE_BITS</emphasis>=[<replaceable>number</replaceable>]</term>
|
||||||
|
@ -219,6 +219,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -220,6 +220,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -219,6 +219,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -219,6 +219,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -219,6 +219,8 @@ WARNOLDCAPVERSION=Yes
|
|||||||
|
|
||||||
WORKAROUNDS=No
|
WORKAROUNDS=No
|
||||||
|
|
||||||
|
ZERO_MARKS=No
|
||||||
|
|
||||||
ZONE2ZONE=-
|
ZONE2ZONE=-
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
@ -2604,6 +2604,23 @@ INLINE - - - ;; -j REJECT
|
|||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term><emphasis role="bold">ZERO_MARKS=</emphasis>[<emphasis
|
||||||
|
role="bold">Yes</emphasis>|<emphasis role="bold">No</emphasis>]</term>
|
||||||
|
|
||||||
|
<listitem>
|
||||||
|
<para>Added in Shorewall 5.0.12, this is a workaround for an issue
|
||||||
|
where packet marks are not zeroed by the kernel. It should be set to
|
||||||
|
No (the default) unless you find that incoming packets are being
|
||||||
|
mis-routed for no apparent reasons.</para>
|
||||||
|
|
||||||
|
<caution>
|
||||||
|
<para>Do not set this option to Yes if you have IPSEC software
|
||||||
|
running on the firewall system.</para>
|
||||||
|
</caution>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term><emphasis
|
<term><emphasis
|
||||||
role="bold">ZONE_BITS</emphasis>=[<replaceable>number</replaceable>]</term>
|
role="bold">ZONE_BITS</emphasis>=[<replaceable>number</replaceable>]</term>
|
||||||
|
Loading…
Reference in New Issue
Block a user