Help wanted: IPTables / ip_masq_ftp
Hi,
I recently reinstalled my linux machine with RedHat 7.1. Before that, I was using Mandrake 7.1 (based on Redhat 6.x). I've converted most of my firewall rules, but I'm stuck with some ftp redirection.
I used the following code on Mandrake:
/usr/sbin/ipmasqadm portfw -f # flush the table
/usr/sbin/ipmasqadm portfw -a -P tcp -L xxx 41 -R yyy 41
/usr/sbin/ipmasqadm portfw -a -P tcp -L xxx 62 -R yyy 62
/usr/sbin/ipmasqadm portfw -l -n
/sbin/modprobe ip_masq_ftp ports=41,62
How can I get the same results with IPTABLES?
I've tried the following (in some varieties..):
IPTABLES -t nat -A PREROUTING -i eth1 -p tcp -sport 41 -j DNAT --to yyy
IPTABLES -t nat -A PREROUTING -i eth1 -p tcp -sport 62 -j DNAT --to yyy
with all 'filter' chains on default policy "Accept" (just to try it out).
Anyone?
regards,
|