Linux Netfilter discussions
 help / color / mirror / Atom feed
* ftp access problem
@ 2004-07-24 10:05 Askar Ali Khan
  2004-07-24 10:22 ` Antony Stone
  0 siblings, 1 reply; 7+ messages in thread
From: Askar Ali Khan @ 2004-07-24 10:05 UTC (permalink / raw)
  To: netfilter

Hi

On my router/firewall which acting i am getting problem while anyone
tries to connect to ftp server he connected successfully however when
he types and command for example "ls" ftp server return error "500
Illegal PORT range rejected"
Everything else is working fine.

default policies are drop

iptables --policy INPUT DROP     
iptables --policy FORWARD DROP 
iptables --policy OUTPUT DROP 
.
.
.
iptables -t nat -A POSTROUTING -o ppp0 -s 192.168.0.0/24 -d 0/0  -j
MASQUERADE#iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j
REDIRECT --to-port 3128
iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A OUTPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A FORWARD -m state --state ESTABLISHED,RELATED -j ACCEPT

For FTP access..
iptables -A FORWARD -o ppp0 -p tcp -m multiport --dport 20,21 -m state
--state NEW -j ACCEPT

I understand that FTP server will also in return open a port on my
side and this is what causing problem. However I don't know which
chain and what rule to make for this to solve this problem. :)

I any quick help in this regard will be greatly appreciated :D

Regards
Askar


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2004-07-24 13:28 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-24 10:05 ftp access problem Askar Ali Khan
2004-07-24 10:22 ` Antony Stone
2004-07-24 11:45   ` Askar Ali Khan
2004-07-24 12:01     ` Martijn Lievaart
2004-07-24 13:00     ` ro0ot
2004-07-24 13:13     ` Antony Stone
2004-07-24 13:28       ` Jeffrey Laramie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox