I just upgraded my machine to RH 9. As a result the script I use to start iptables had a problem with the setting a variable named DHCP_SERVER that should hold the IP address of the DHCP server that services my machine.
The script is taken from the tutorial by the great Oskar Andreasson
On RH7.3 I did the following: DHCP_SERVER=`grep 'DHCPSID=' /etc/dhcpcd/dhcpcd-eth0.info | cut -f 2 -d "="`
The best thing I could come up with on RH 9 is:
DHCP_SERVER=`grep 'dhcp-server-identifier' /var/lib/dhcp/dhclient-eth0.leases | \
head -1 | tr -s ' ' | cut -f 4 -d ' '| cut -f 1 -d ';'`
To me this statement looks bad. Any recommendations?
References to the tutorial and the script. http://www.linuxsecurity.com/resource_files/firewalls/IPTables-Tutorial/iptables-tutorial.html
http://iptables-tutorial.frozentux.net/scripts/rc.DHCP.firewall.txt
================================================================= To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]