Hi All,
I have an FTP server in DMZ and I cannot get Directory listing.
The FTP uses FTP over SSL on 10.0.0.2 and passive connection is allowed
from ports 5000-5005
I can connect to the server but its only the directory listing which is
not availble.
Any help will be very appreciated.
And my firewall rule is a follows
#!/bin/sh
IPTABLES="/usr/sbin/iptables"
LAN_IFACE=eth1
INET_IFACE=eth0
# Flush all chains
$IPTABLES -F FORWARD
$IPTABLES -F INPUT
$IPTABLES -F OUTPUT
$IPTABLES -F
$IPTABLES -X
$IPTABLES -t nat -F
$IPTABLES -t nat -X
# Enable forwarding
echo 1 > /proc/sys/net/ipv4/ip_forward
# Set default policies
$IPTABLES --policy INPUT DROP
$IPTABLES --policy OUTPUT DROP
$IPTABLES --policy FORWARD DROP
# Allow unlimited traffic on the loopback interface
$IPTABLES -A INPUT -i lo -j ACCEPT
$IPTABLES -A OUTPUT -o lo -j ACCEPT
# Allow SSH connection
$IPTABLES -A INPUT -p tcp -s 0/0 --dport 22 -j ACCEPT
# Accepting FTP connection
$IPTABLES -A INPUT -p tcp -s 0/0 --dport 21 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -p tcp --dport 21 -j DNAT --to 10.0.0.2:21
# Allowing higher ports for passive connection to Fileserver1
$IPTABLES -A INPUT -p tcp --dport 5000:5005 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -p tcp --dport 5000:5005 -j DNAT --to
10.0.0.2
$IPTABLES -t nat -A POSTROUTING -d 10.0.0.2 -j MASQUERADE
# Allow related/maintain connections
$IPTABLES -A FORWARD -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT
# Allow unlimited outbound traffic
$IPTABLES -A OUTPUT -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT
## EOF ##
Kind Regards,
Prashant
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems