Re: ipnat port-range



Le Sun, 17 May 2009 16:16:51 -0400,
alexus <alexus@xxxxxxxxx>:

i dont see how things are obvious for you as they not so obvious for
me. first of all my ipf default policy to allow everything.

so the original question is for ipnat and not for ipf

now for non-passive (active) i put in these rules

rdr bce0 0/0 port ftp-data -> lama port ftp-data tcp
rdr bce0 0/0 port ftp -> lama port ftp tcp

and for pasv i still dont know what to do

i've tried

rdr bce0 0/0 port 49152-65534 -> lama port 65534

and in my ftp i said that this is range for pasv connections

I don't think there is a way to redirect a ports ranges to a ports
range with ipnat. For my ftp server I redirect each port (I use 30000
to 30039 for FTP) with a rule:
rdr vr0 0.0.0.0/0 port 21 -> 192.168.1.4 port 21
rdr vr0 0.0.0.0/0 port 30000 -> 192.168.1.4 port 30000
rdr vr0 0.0.0.0/0 port 30001 -> 192.168.1.4 port 30001
...
rdr vr0 0.0.0.0/0 port 30038 -> 192.168.1.4 port 30038
rdr vr0 0.0.0.0/0 port 30039 -> 192.168.1.4 port 30039

For ipnat see
http://www.westworks.ch/~chris/netbsd/NetBSD-NAT-FTP-server.html

Regards.
_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: ipnat port-range
    ... Ipnat and FTP PASV is covered extensively in the ipfilter howto on ... pass out quick on external_interface proto tcp from any port 1023>< 2025 to ...
    (freebsd-questions)
  • Re: ipnat port-range
    ... first of all my ipf default policy to allow everything. ... rdr bce0 0/0 port ftp -> lama port ftp tcp ... range with ipnat. ...
    (freebsd-questions)
  • Re: problems with ipfw + natd rules
    ... I tried to allow only 80 port, but the result is the same. ... ipf + ipnat, but i need to block internet connection to some users by MAC ...
    (freebsd-questions)
  • RE: best firewall option for FreeBSD
    ... FTP can be handled by IPfilter. ... Refer to the IPfilter HOW-TO documentation. ... since the source IP and port now match the established connection ... ... You can try to direct all the ftp traffic to natd, or ipnat. ...
    (FreeBSD-Security)
  • RE: Telnet/ftp problems SBS2000
    ... Please make sure your client computers are configured as both Firewall ... will find two options "Enable folder view for FTP sites" and "Use Passive ... that the control connection has been successfully established, ... (other than port 21) ...
    (microsoft.public.windows.server.sbs)