LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Urgent: IP masquerading in Debian 3.0 (https://www.linuxquestions.org/questions/debian-26/urgent-ip-masquerading-in-debian-3-0-a-78557/)

swmok 08-03-2003 08:56 AM

Urgent: IP masquerading in Debian 3.0
 
Do I need to re-compile the kernel?
Or, the kernel is already support the IP masquerading?

wallison 08-03-2003 09:45 AM

apt-get install ipmasq did the trick for me.

whaley 08-07-2003 11:52 AM

iptables or ipchains?
 
I prefer to use iptables. I've found it to be much easier to use and more flexible than ipchains. It's quite easy to set up..

Download a 2.4 kernel and compile it.
Here are the relevant options using 2.4.21 from .config. I've put them in a link because they are too long to include here.

After you recompile (don't forget to include all your other options!), use these two commands:

echo 1 > /proc/sys/net/ipv4/ip_forward
/sbin/iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE

Where eth1 is your EXTERNAL interface. You may need to look at your routing tables (route -n) to make it work correctly.

Note that this is a WIDE OPEN configuration and provides
NO security. Beware! See the IP tables howto for information on a more secure setup.

Hope that helps...


All times are GMT -5. The time now is 11:41 PM.