Defcon1-Header
Tool-BarfreeBSD ArticlesSearch Our SiteHOMEfreeBSD LinksContribute to FreeBSD HelpFreeBSD FilesFreeBSD Script Corner

Guide to setting up IPfilter

So you want to share your new DSL or cable modem connection with all of the machines on your LAN, no problem. You can do this with ipnat, a program that is part of the ipfilter firewall package.

You will need to add two lines to your kernel to allow ipfilter to work.

options IPFILTER

options IPFILTER_LOG

Compile these if you kernel and reboot.

Now you need a file called /etc/ipnat.rules. In this file you need to have the following

map ed0 10.0.0.0/24 -> 208.208.208.208/32

ed0 needs to be your nic that has a real ip and the 208.208.208.208 needs to be your real ip

then create/add to your /etc/rc.local file with the line:

ipnat -f /etc/ipnat.rules

 

That way it fires ipnat when you boot up. If you want to fire up ipnat without rebooting, just type:

ipnat -f /etc/ipnat.rules

This should get you started, for more info check out http://coombs.anu.edu.au/~avalon for the official ipfilter website.

© 1997 - 20013 Defcon1, www.defcon1.org , Copyrights for all materials on this web site are held by the individual authors, artists, photographers or creators. Materials may not be reproduced or otherwise distributed without permission of www.defcon1.org and the content's original author.

Defcon1-Header2
Tool-Bar-2Defcon1  Webmail