Allow host-list in /etc/shorewall/hosts again

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@164 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2002-07-29 14:31:50 +00:00
parent 10b5589304
commit 63bc520aa9

View File

@ -536,7 +536,8 @@ validate_hosts_file() {
r="$z $hosts $options"
validate_zone $z || startup_error "Invalid zone ($z) in record \"$r\""
interface=${hosts%:*}
for host in `separate_list $hosts`; do
interface=${host%:*}
list_search $interface $all_interfaces || \
startup_error "Unknown interface ($interface) in record \"$r\""
@ -550,6 +551,7 @@ validate_hosts_file() {
;;
esac
done
done
done < $TMP_DIR/hosts
}
@ -2588,7 +2590,7 @@ verify_os_version() {
################################################################################
# Add IP Aliases #
################################################################################
add_ip_aliases() # $* = addresses and devices
add_ip_aliases()
{
do_one()
{
@ -2620,6 +2622,8 @@ add_ip_aliases() # $* = addresses and devices
echo " IP Address $external added to interface $interface"
}
set -- $aliases_to_add
while [ $# -gt 0 ]; do
external=$1
interface=$2
@ -3199,7 +3203,7 @@ define_firewall() # $1 = Command (Start or Restart)
[ -n "$aliases_to_add" ] && \
echo "Adding IP Addresses..." && \
add_ip_aliases $aliases_to_add
add_ip_aliases
run_user_exit start