Re: FTP accelerator

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Fri, 02 Nov 2001 07:28:45 +0100

Squid only implements a direct mapping of HTTP to FTP requests, acting
as a HTTP->FTP gateway.

Caching is done according to HTTP rules on the result of the above
mapping.

What Squid can easily do is to provide cached HTTP entry points to a FTP
service. This only requires a redirector (or the squid-rproxy branch).

Implementing a FTP proxy side in Squid is possible, but does not mix
very well with anything there currently is. Further, the FTP protocol is
as I said very stateful and unfortunately slightly ambiguous which
complicates caching somewhat.

The ambiguity can mostly be resolved by making use of PWD when building
the object identities, but unfortunately some FTP servers have bugs in
PWD, but even when using PWD it is close to impossible to know all state
related to the object. For example there is FTP servers that have more
than one "ascii" translation variant.

Theoretically one is supposed to be able to use the STAT command to tell
the rest of state, but the format of the result is not specified so
support for each and every FTP server brand one wants to support needs
to be coded manually..

In all, FTP is a quite ugly protocol to cache.

But sure, if you are doing a special purpose FTP cache, then most of the
above gets a lot simpler as you then only have to worry about the
peculiarities of one FTP server.

Regards
Henrik

Roger Venning wrote:
>
> Henrik,
>
> what is meant is that Squid does not implement an ftp interface on the
> cilent side, just on the origin server side, yes? Any feelings how hard
> it might be given the current internal implementation of an ftp client?
>
> Roger.
>
> ----- Original Message -----
> From: Henrik Nordstrom <hno@squid-cache.org>
> Date: Friday, November 2, 2001 6:14 am
> Subject: Re: FTP accelerator
>
> > Only that Squid does not implement the FTP protocol, and that FTP
> > is a
> > bit tricker to cache than HTTP due to the ambigous statefullness
> > of the
> > protocol.
> >
> >
> > Note: When Squid caches ftp:// URLs, it does so as a HTTP proxy, which
> > is both stateless and non-ambigous.
> >
> > Regards
> > Henrik
> >
> >
> > Andres Kroonmaa wrote:
> > >
> > > It has got me some time ago that Squid could be quite efficient
> > > dedicated FTP accelerator for some remote site, or even local
> > > anon-only FTP server.
> > > Is there anything fundamentally wrong with this idea?
> > >
> > > ------------------------------------
> > > Andres Kroonmaa <andre@online.ee>
> > > CTO, Microlink Online
> > > Tel: 6501 731, Fax: 6501 725
> > > Pärnu mnt. 158, Tallinn,
> > > 11317 Estonia
> >
>
Received on Thu Nov 01 2001 - 23:58:06 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:14:37 MST