|
-
IPChains and DHCP
Has anyone using IPChains for IP Forwarding/Masquerading with a network
card that uses DHCP? I am curious because, in all the examples I have
seen, IPChains requires IP addresses for routing. I already have an
IPChains script that creates a firewall, I just need a way to handle
DHCP on one network card.
-- Joel
-
Re: IPChains and DHCP
Joel Ryan <jryan@vsi-hq.com> wrote:
>Has anyone using IPChains for IP Forwarding/Masquerading with a network
>card that uses DHCP? I am curious because, in all the examples I have
>seen, IPChains requires IP addresses for routing. I already have an
>IPChains script that creates a firewall, I just need a way to handle
>DHCP on one network card.
>-- Joel
>
Joel,
All you have to do is add:
#******************************************************
# DHCP STUFF
#******************************************************
#
/sbin/ipchains -A input -j ACCEPT -i eth0 -s 0/0 67 -d 0/0 68 -p udp
echo 1 > /proc/sys/net/ipv4/ip_forward
#
#Timeouts needed for DHCP requests
#1 hr timeout fot TCP timeouts
#10 sec timeout for traffic after the TCP/IP "FIN" packet is received
#160 sec timeout for UDP traffic (Important for MASQ'ed ICQ users)
/sbin/ipchains/-M -S 3600 10 160
#
#Be sure to edit /etc/sysconfig/network from:
#FORWARD_IPV4=false
#to
#FORWARD_IPV4=true
This should do it.
shaken
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks