natd redirect help

Lowell Gilbert freebsd-questions-local at be-well.ilk.org
Fri Oct 21 05:54:06 PDT 2005


"Efren Bravo" <efrenba at dhl.co.cu> writes:

> Hi,
> 
> I've a freebsd5.4 with ipfw and natd. I need that external users can enter
> to my internal network services (http, ftp, etc). 
> 
> freebsd box:
> out interface: 200.x.x.x
> in interface: 10.x.x.x
> 
> /etc/rc.conf file:
> ------------------
> gateway_enable="YES"
> 
> firewall_enable="YES"
> firewall_script="/etc/ipfw.rules"
> firewall_logging="YES"
> 
> natd_enable="YES"
> natd_interface="vr0"
> natd_flags="-f /etc/natd.conf"
> 
> /etc/natd.conf file:
> --------------------
> redirect_port tcp 10.x.x.x:8080 80 #redirec to internal web server
> 
> 
> The question is if I've to open the port 80 on freeBSD's vr0 because I not
> able to enter to those services.

The packet will be checked again after it's been through natd, so you
need an accept rule for it somewhere.  But at that point, I guess it
should be destined for port 8080 rather than 80.


More information about the freebsd-questions mailing list