[jcifs] Re: directory must end with '/'
Christopher R. Hertel
crh at ubiqx.mn.org
Thu Dec 9 10:40:06 GMT 2004
On Thu, Dec 09, 2004 at 10:18:07AM +0100, Julian Reschke wrote:
> Christopher R. Hertel wrote:
> >...
> >I think (once again) that this is why HTTP creates the semantic
> >distinction and adds the empty path segment (that is, the trailing slash)
> >to a directory name.
> >...
>
> Where do you get this impression from?
You're right. It's clearly not part of the protocol. There is, however,
a convention which says that if the URL received by the web server
resolves to a directory on the server side, then the URL should be
"corrected" by adding a slash. The "corrected" URL is then sent back to
the client via the redirect, as you describe below.
So... those semantics do exist (somewhere) and they are handled--by
convention--by adding the slash.
Does that description make sense?
> As far as I can tell, RFC2616
> doesn't even have a defined concept for a directory. Why would it, as
> there are no RFC2616-methods for which it would make a difference?
I should mention that under SMB there is the concept of a directory.
> If an existing HTTP server sends a redirect upon accessing a directory,
> that is an *implementation detail* (that's required to make relative
> references work). It has nothing to do with the protocol itself.
Yep. I got it.
> Some more pointers:
>
> RFC2518 (<http://greenbytes.de/tech/webdav/rfc2518.html>) defines
> collections (and does *not* explicitly require trailing slashes on
> collections)
I'll have to take a look at this and RFC 2616 when I get a chance.
> RFC2396bis
> (<http://greenbytes.de/tech/webdav/draft-fielding-uri-rfc2396bis-07.html>)
> obsoletes RFC2396.
Yeah, I was aware they were working on this. It's still a draft, but
there's an IETF coming up in a few months near my home so I'll probably be
going and should be up on this.
Thanks!
Chris -)-----
--
"Implementing CIFS - the Common Internet FileSystem" ISBN: 013047116X
Samba Team -- http://www.samba.org/ -)----- Christopher R. Hertel
jCIFS Team -- http://jcifs.samba.org/ -)----- ubiqx development, uninq.
ubiqx Team -- http://www.ubiqx.org/ -)----- crh at ubiqx.mn.org
OnLineBook -- http://ubiqx.org/cifs/ -)----- crh at ubiqx.org
More information about the jcifs
mailing list