Suppress DHCP message when there are no DHCP rules

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@666 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2003-07-18 23:12:34 +00:00
parent 5a6e9b7c56
commit afd7840558
3 changed files with 15 additions and 6 deletions

View File

@ -48,4 +48,6 @@ Changes since 1.4.5
20. Display policy chain along with policy in 'check' command.
21. Support Linux 2.6 compressed modules.
21. Support Linux 2.6 compressed modules.
22. Don't display DHCP message when there are no DHCP interface.

View File

@ -3615,13 +3615,17 @@ add_common_rules() {
#
# DHCP
#
echo "Adding rules for DHCP"
interfaces=`find_interfaces_by_option dhcp`
for interface in `find_interfaces_by_option dhcp`; do
run_iptables -A `input_chain $interface` -p udp --dport 67:68 -j ACCEPT
run_iptables -A OUTPUT -o $interface -p udp --dport 67:68 -j ACCEPT
done
if [ -n "$interfaces" ]; then
echo "Adding rules for DHCP"
for interface in $interfaces; do
run_iptables -A `input_chain $interface` -p udp --dport 67:68 -j ACCEPT
run_iptables -A OUTPUT -o $interface -p udp --dport 67:68 -j ACCEPT
done
fi
#
# RFC 1918
#

View File

@ -17,6 +17,9 @@ Problems Corrected:
4) The handling of z1!z2 in the SOURCE column of DNAT and REDIRECT
rules has been corrected.
5) The message "Adding rules for DHCP" is now suppressed if there are
no DHCP rules to add.
Migration Issues:
1) In earlier versions, an undocumented feature allowed entries in