mirror of
https://gitlab.com/shorewall/code.git
synced 2025-06-24 11:41:26 +02:00
Raise an error when a server list is specified in a DNAT or REDIRECT rule
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
1892cbf218
commit
9c9ae04c86
@ -633,7 +633,7 @@ sub setup_netmap() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#
|
#
|
||||||
# Called from process_rule1 to add a rule to the NAT table
|
# Called from process_rule to add a rule to the NAT table
|
||||||
#
|
#
|
||||||
sub handle_nat_rule( $$$$$$$$$$$$$ ) {
|
sub handle_nat_rule( $$$$$$$$$$$$$ ) {
|
||||||
my ( $dest, # <server>[:port]
|
my ( $dest, # <server>[:port]
|
||||||
@ -687,6 +687,11 @@ sub handle_nat_rule( $$$$$$$$$$$$$ ) {
|
|||||||
#
|
#
|
||||||
$server = $dest;
|
$server = $dest;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#
|
||||||
|
# Check for list in $server
|
||||||
|
#
|
||||||
|
fatal_error "An address list is not allowed in the DEST column of a $action RULE" if $server =~ /,/;
|
||||||
#
|
#
|
||||||
# Generate the target
|
# Generate the target
|
||||||
#
|
#
|
||||||
|
Loading…
x
Reference in New Issue
Block a user