All of lore.kernel.org
 help / color / mirror / Atom feed
* Firewall and a FTP server
@ 2005-12-19 11:52 TAC Forums
  2005-12-19 12:08 ` Askar Ali
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: TAC Forums @ 2005-12-19 11:52 UTC (permalink / raw)
  To: netfilter

Hi All,

We have a FTP server, (Red Hat Linux 7) behind a firewall, the
firewall allows only incomming and established connections on ports
20,21  from any where and evry where.

The Problem is, when the customers use FTP clients, the manage to
login , but cannot upload/download files if they use PASSIVE FTP
connections.

Can smeone suggest, how the best way to get out of this situation,
should we enable all ports above 1023?

Regards,
Boskey

--
TAC Support Team


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

* Re: Firewall and a FTP server
  2005-12-19 11:52 Firewall and a FTP server TAC Forums
@ 2005-12-19 12:08 ` Askar Ali
  2005-12-20  5:30   ` TAC Forums
  2005-12-19 15:15 ` Firewall and a FTP server (nfcan: addressed to exclusive sender for this address) Jim Laurino
  2005-12-19 16:15 ` Firewall and a FTP server Marcin Krol
  2 siblings, 1 reply; 7+ messages in thread
From: Askar Ali @ 2005-12-19 12:08 UTC (permalink / raw)
  To: TAC Forums; +Cc: netfilter

TAC Forums wrote:

>Hi All,
>
>We have a FTP server, (Red Hat Linux 7) behind a firewall, the
>  
>
why are you still using historic version of rh ? :)

>firewall allows only incomming and established connections on ports
>20,21  from any where and evry where.
>
>The Problem is, when the customers use FTP clients, the manage to
>login , but cannot upload/download files if they use PASSIVE FTP
>connections.
>
>Can smeone suggest, how the best way to get out of this situation,
>should we enable all ports above 1023?
>
>Regards,
>Boskey
>
>--
>TAC Support Team
>
>
>  
>
hi Tac

verify that modules

ip_conntrack_ftp
ip_nat_ftp

are loaded, if not try to load them with "modprobe ip_conntrack_ftp" and 
put it in your firewall startup script so that modules at boot time.




regards,

askar


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

* RE: Firewall and a FTP server
@ 2005-12-19 14:31 Derick Anderson
  0 siblings, 0 replies; 7+ messages in thread
From: Derick Anderson @ 2005-12-19 14:31 UTC (permalink / raw)
  To: TAC Forums, netfilter

 

> -----Original Message-----
> From: netfilter-bounces@lists.netfilter.org 
> [mailto:netfilter-bounces@lists.netfilter.org] On Behalf Of Askar Ali
> Sent: Monday, December 19, 2005 7:09 AM
> To: TAC Forums
> Cc: netfilter@lists.netfilter.org
> Subject: Re: Firewall and a FTP server
> 
> TAC Forums wrote:
> 
> >Hi All,
> >
> >We have a FTP server, (Red Hat Linux 7) behind a firewall, the
> >  
> >
> why are you still using historic version of rh ? :)
> 
> >firewall allows only incomming and established connections on ports
> >20,21  from any where and evry where.
> >
> >The Problem is, when the customers use FTP clients, the 
> manage to login 
> >, but cannot upload/download files if they use PASSIVE FTP 
> connections.
> >
> >Can smeone suggest, how the best way to get out of this situation, 
> >should we enable all ports above 1023?
> >
> >Regards,
> >Boskey
> >
> >--
> >TAC Support Team
> >
> >
> >  
> >
> hi Tac
> 
> verify that modules
> 
> ip_conntrack_ftp
> ip_nat_ftp
> 
> are loaded, if not try to load them with "modprobe 
> ip_conntrack_ftp" and put it in your firewall startup script 
> so that modules at boot time.
> 
> 
> 
> 
> regards,
> 
> askar

If you don't have those modules in the kernel you will need to open up
NEW connections for the passive ports on your FTP server or recompile
your kernel. I've done the port-opening thing when recompiling the
kernel on a live firewall was more downtime than the PTB were willing to
accept.

Derick Anderson 


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

* Re: Firewall and a FTP server (nfcan: addressed to exclusive sender for this address)
  2005-12-19 11:52 Firewall and a FTP server TAC Forums
  2005-12-19 12:08 ` Askar Ali
@ 2005-12-19 15:15 ` Jim Laurino
  2005-12-19 16:15 ` Firewall and a FTP server Marcin Krol
  2 siblings, 0 replies; 7+ messages in thread
From: Jim Laurino @ 2005-12-19 15:15 UTC (permalink / raw)
  To: netfilter

On 2005.12.19 06:52, TAC Forums - tac.forums@gmail.com wrote:
> Hi All,
> 
> We have a FTP server, (Red Hat Linux 7) behind a firewall, the
> firewall allows only incomming and established connections on ports
> 20,21  from any where and evry where.
> 
> The Problem is, when the customers use FTP clients, the manage to
> login , but cannot upload/download files if they use PASSIVE FTP
> connections.
> 
> Can smeone suggest, how the best way to get out of this situation,
> should we enable all ports above 1023?

Besides loading the modules, as already discussed,
you need to change the filter rules to allow
not only ESTABLISHED but also RELATED connections.
This eliminates the need to open all the high ports.
The new rule would look something like this:

$IPT -A FORWARD -m state --state ESTABLISHED,RELATED -j ACCEPT

-- 
Jim Laurino
nfcan.x.jimlaur@dfgh.net
Please reply to the list.
Only mail from the listserver reaches this address.


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

* Re: Firewall and a FTP server
  2005-12-19 11:52 Firewall and a FTP server TAC Forums
  2005-12-19 12:08 ` Askar Ali
  2005-12-19 15:15 ` Firewall and a FTP server (nfcan: addressed to exclusive sender for this address) Jim Laurino
@ 2005-12-19 16:15 ` Marcin Krol
  2005-12-20  1:19   ` ludi
  2 siblings, 1 reply; 7+ messages in thread
From: Marcin Krol @ 2005-12-19 16:15 UTC (permalink / raw)
  To: TAC Forums; +Cc: netfilter

Hello TAC,

TF> We have a FTP server, (Red Hat Linux 7) behind a firewall, the
TF> firewall allows only incomming and established connections on ports
TF> 20,21  from any where and evry where.

TF> The Problem is, when the customers use FTP clients, the manage to
TF> login , but cannot upload/download files if they use PASSIVE FTP
TF> connections.

TF> Can smeone suggest, how the best way to get out of this situation,
TF> should we enable all ports above 1023?

If you use VSFTPD (recommended), there's a directive there that tells
the daemon to open a port from a selected range of ports - that should
be more secure.


-- 
Best regards,
 Marcin                            mailto:mark@wbp.krakow.pl




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

* Re: Firewall and a FTP server
  2005-12-19 16:15 ` Firewall and a FTP server Marcin Krol
@ 2005-12-20  1:19   ` ludi
  0 siblings, 0 replies; 7+ messages in thread
From: ludi @ 2005-12-20  1:19 UTC (permalink / raw)
  To: netfilter

HI, I have the same problem. I have a  proftp and setup a script on
the server to start the IPTABLES. I had load the ip_conntrack_ftp .
But my client still can not connect to the ftp by "PASSIVE" mode.
Thx

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

* Re: Firewall and a FTP server
  2005-12-19 12:08 ` Askar Ali
@ 2005-12-20  5:30   ` TAC Forums
  0 siblings, 0 replies; 7+ messages in thread
From: TAC Forums @ 2005-12-20  5:30 UTC (permalink / raw)
  To: Askar Ali; +Cc: netfilter

Hi Askar,

On 12/19/05, Askar Ali <askarali@gmail.com> wrote:
> TAC Forums wrote:
>
> >Hi All,
> >
> >We have a FTP server, (Red Hat Linux 7) behind a firewall, the
> >
> >
> why are you still using historic version of rh ? :)
>
Well, we are stuck with a Sun Cobalt Raq 550 server for our life!!

> >firewall allows only incomming and established connections on ports
> >20,21  from any where and evry where.
> >
> >The Problem is, when the customers use FTP clients, the manage to
> >login , but cannot upload/download files if they use PASSIVE FTP
> >connections.
> >
> >Can smeone suggest, how the best way to get out of this situation,
> >should we enable all ports above 1023?
> >
> >Regards,
> >Boskey
> >
> >--
> >TAC Support Team
> >
> >
> >
> >
> hi Tac
>
> verify that modules
>
> ip_conntrack_ftp
> ip_nat_ftp
>
> are loaded, if not try to load them with "modprobe ip_conntrack_ftp" and
> put it in your firewall startup script so that modules at boot time.
>
>
Thank you, ths is already done.
Regards,
Boskey
>
>
> regards,
>
> askar
>


--
TAC Support Team


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

end of thread, other threads:[~2005-12-20  5:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-12-19 11:52 Firewall and a FTP server TAC Forums
2005-12-19 12:08 ` Askar Ali
2005-12-20  5:30   ` TAC Forums
2005-12-19 15:15 ` Firewall and a FTP server (nfcan: addressed to exclusive sender for this address) Jim Laurino
2005-12-19 16:15 ` Firewall and a FTP server Marcin Krol
2005-12-20  1:19   ` ludi
  -- strict thread matches above, loose matches on Subject: below --
2005-12-19 14:31 Derick Anderson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.