forked from extern/shorewall_code
Correct splitting of IP(6)TABLES options
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
5bc724c268
commit
1d1068ac74
@ -122,7 +122,7 @@ sub process_conntrack_rule( $$$$$$$$$$ ) {
|
||||
fatal_error "Invalid conntrack ACTION (IPTABLES)" unless $1;
|
||||
}
|
||||
|
||||
my ( $tgt, $options ) = split( ' ', $2 );
|
||||
my ( $tgt, $options ) = split( ' ', $2, 2 );
|
||||
my $target_type = $builtin_target{$tgt};
|
||||
fatal_error "Unknown target ($tgt)" unless $target_type;
|
||||
fatal_error "The $tgt TARGET is not allowed in the raw table" unless $target_type & RAW_TABLE;
|
||||
|
@ -2915,7 +2915,7 @@ sub process_rule ( $$$$$$$$$$$$$$$$$$$$ ) {
|
||||
IPTABLES => sub {
|
||||
if ( $param ) {
|
||||
fatal_error "Unknown ACTION (IPTABLES)" unless $family == F_IPV4;
|
||||
my ( $tgt, $options ) = split / /, $param;
|
||||
my ( $tgt, $options ) = split / /, $param, 2;
|
||||
my $target_type = $builtin_target{$tgt};
|
||||
fatal_error "Unknown target ($tgt)" unless $target_type;
|
||||
fatal_error "The $tgt TARGET is not allowed in the filter table" unless $target_type & FILTER_TABLE;
|
||||
@ -2928,7 +2928,7 @@ sub process_rule ( $$$$$$$$$$$$$$$$$$$$ ) {
|
||||
IP6TABLES => sub {
|
||||
if ( $param ) {
|
||||
fatal_error "Unknown ACTION (IP6TABLES)" unless $family == F_IPV6;
|
||||
my ( $tgt, $options ) = split / /, $param;
|
||||
my ( $tgt, $options ) = split / /, $param, 2;
|
||||
my $target_type = $builtin_target{$tgt};
|
||||
fatal_error "Unknown target ($tgt)" unless $target_type;
|
||||
fatal_error "The $tgt TARGET is not allowed in the filter table" unless $target_type & FILTER_TABLE;
|
||||
@ -4499,7 +4499,7 @@ sub process_mangle_rule1( $$$$$$$$$$$$$$$$$$ ) {
|
||||
maxparams => 1,
|
||||
function => sub () {
|
||||
fatal_error "Invalid ACTION (IPTABLES)" unless $family == F_IPV4;
|
||||
my ( $tgt, $options ) = split( ' ', $params );
|
||||
my ( $tgt, $options ) = split( ' ', $params, 2 );
|
||||
my $target_type = $builtin_target{$tgt};
|
||||
fatal_error "Unknown target ($tgt)" unless $target_type;
|
||||
fatal_error "The $tgt TARGET is not allowed in the mangle table" unless $target_type & MANGLE_TABLE;
|
||||
@ -4515,7 +4515,7 @@ sub process_mangle_rule1( $$$$$$$$$$$$$$$$$$ ) {
|
||||
maxparams => 1,
|
||||
function => sub () {
|
||||
fatal_error "Invalid ACTION (IP6TABLES)" unless $family == F_IPV6;
|
||||
my ( $tgt, $options ) = split( ' ', $params );
|
||||
my ( $tgt, $options ) = split( ' ', $params, 2 );
|
||||
my $target_type = $builtin_target{$tgt};
|
||||
fatal_error "Unknown target ($tgt)" unless $target_type;
|
||||
fatal_error "The $tgt TARGET is not allowed in the mangle table" unless $target_type & MANGLE_TABLE;
|
||||
|
Loading…
Reference in New Issue
Block a user