lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: LYNX-DEV /foo/.. ?


From: Foteos Macrides
Subject: Re: LYNX-DEV /foo/.. ?
Date: Sat, 02 Nov 1996 15:04:03 -0500 (EST)

"Benjamin C. W. Sittler" <address@hidden> wrote:
>On Sat, 2 Nov 1996, Wayne Buttles wrote:
>
>> Can someone explain the /foo/.. hack for me in htftp.c, htfile.c and
>> html.c?
>
>Here's my understanding (could be flawed):
>
>the following FTP command:
>cd /
>may not be equivalent to
>cd /
>cd foo
>cd ..
>(or cd /foo/..)
>
>because of symbolic links. We don't have this problem with HTTP, really,
>but we do with Unix filesystems, which is why I'm guessing it's in htfile
>too.

        Interesting guess! :) :)
        
        It's a Lynx-specific hack Lou did many years ago to get around
the assumption in several modules of the libwww that RFC 1738 should be
respected in the FTP gateway.  That RFC species that the '/' between
the host and path in ftp://host/path URLs is purely a field separator,
and does not specify the root.  If you do want the root, according
to RFC 1738, you should use ftp://host/%2Fpath whereas if you don't
precede the path with an escaped slash then the path should be treated
as a file or subdirectory in or under the ftp login directory.

        Lynx does respect RFC 1738 for VMS and VM/CMS ftp servers,
but for Unix and Unix-like ftp servers it treats the path equivalently
to the handling for file://localhost/path URLs.  For real Unix ftp
servers, you can use a tilde to set the path as originating at the
login directory, analogously to file URLs.  One difference is that
for ftp you can include any username, e.g., ftp://address@hidden/~you
because the server will check access rights of "me" to "you"'s
account, but the tilde is always treated as having an implied "me"
for file URLs (for security reasons).

        See the "Supported URLs" section of the online 'h'elp for
more information about ftp and file URLs.  The /foo/.. is created
only when using the ftp gateway in Lynx, and you should forget you
ever saw it, i.e., not try to figure it out and use it in external
documents. :) :) :)

                                Fote

=========================================================================
 Foteos Macrides            Worcester Foundation for Biomedical Research
 address@hidden         222 Maple Avenue, Shrewsbury, MA 01545
=========================================================================
;
; To UNSUBSCRIBE:  Send a mail message to address@hidden
;                  with "unsubscribe lynx-dev" (without the
;                  quotation marks) on a line by itself.
;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]