Ok, first, I must say RTFM. That said, here's a quick fix, and a rough idea
of what you should do:
In the /etc/rc.conf file, set the following variables:
natd_enable="YES"
natd_interface="you public interface (e.g. rl0, ed0, dc0, etc)"
gateway_enable="YES"
ifconfig_(inside interface)="inet private.ip.address.here"
ifconfig_(public interface)="DHCP, or however you obtain IP addy"
From there, you should be able to start all this with a /etc/netstart
command as root. This will renew the public IP address, and set your
internal address and outside address.
I hope this helps.
--
Eric F Crist
President/Sys Admin
AdTech Integrated Systems, Inc.
http://www.adtechintegrated.com
Quote:> Hi,
> I have a Linux box that shares my Internet connection. I would like
> to try it with FreeBSD. Here's the hardware setup:
> PII 333, 128mb Ram
> 2 ethernet Nics (one for the cable modem: DHCP, the other one goes in
> my hub)
> With Linux I had to make a small script of 4 or 5 lines with ipchains.
> How can I do it with FreeBSD? Security is not an issue for the
> moment, I just want to know how to route packets from a nic to the
> other (Masquerading...)
> Thank you.