From 42ae3ba5819df88e73ee3ea59c6d212689267f9c Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Sat, 30 Jul 2011 06:57:18 -0700 Subject: [PATCH] Cleaner fix for TCP_FLAGS_DISPOSITION Signed-off-by: Tom Eastep --- Shorewall/Perl/Shorewall/Config.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Shorewall/Perl/Shorewall/Config.pm b/Shorewall/Perl/Shorewall/Config.pm index 481881b91..9f2a6a5df 100644 --- a/Shorewall/Perl/Shorewall/Config.pm +++ b/Shorewall/Perl/Shorewall/Config.pm @@ -3703,12 +3703,12 @@ sub get_configuration( $$$ ) { } if ( $val = $config{TCP_FLAGS_DISPOSITION} ) { - fatal_error "Invalid value ($config{TCP_FLAGS_DISPOSITION}) for TCP_FLAGS_DISPOSITION" unless $val =~ /^(?:(?:A_)?(?:REJECT|DROP)|ACCEPT)$/; + fatal_error "Invalid value ($config{TCP_FLAGS_DISPOSITION}) for TCP_FLAGS_DISPOSITION" unless $val =~ /^(?:(A_)?(?:REJECT|DROP))|ACCEPT$/; + require_capability 'AUDIT_TARGET' , "TCP_FLAGS_DISPOSITION=$val", 's' if $1; } else { $val = $config{TCP_FLAGS_DISPOSITION} = 'DROP'; } - require_capability 'AUDIT_TARGET' , "TCP_FLAGS_DISPOSITION=$val", 's' if $val =~ /^A_/; default 'TC_ENABLED' , $family == F_IPV4 ? 'Internal' : 'no';