file:/ vs file://<host>/ vs file:///
Joerg.Barfurth at sun.com
Thu Nov 4 19:05:04 EET 2004
Glenn McGrath wrote:
> On Thu, 4 Nov 2004 10:02:16 -0500
> Daniel Veillard <veillard at redhat.com> wrote:
>>On Thu, Nov 04, 2004 at 11:45:36PM +1100, Glenn McGrath wrote:
>>>The file-uri-spec says that "file:/<path>" shouldnt be used as it
>>>isnt correct according to RFC1738.
>>>The file-uri-spec says we should use file://localhost/<path> or
>>>RFC2396 says the format of a URI is
>>>absoluteURI = scheme ":" ( hier_part | opaque_part )
>>>hier_part = ( net_path | abs_path ) [ "?" query ]
>>>net_path = "//" authority [ abs_path ]
>>>abs_path = "/" path_segments
>>>Clearly file:/<path> is compatable with RFC2396
>>>The "//" seperator is meant to represent a network location. I think
>>>its very unlikely that the file scheme would be used with a remote
>>>host, so it doenst make much sense. Using "localhost" or not
>>>specifying a host as a way of trying to negating the meaning of "//"
>>>is confusing and not necessary.
>>>As "//localhost" is a net_path redirected to the the local machine,
>>>why not just use "/", the abs_path, it seems it was designed for
>> no. RFC2396 does not override RFC1738 on the matter of defining the
> RFC1738 says file://<host>/<path> is ok, this rfc doesnt mention
> abs_path at all, it only talks about net_path.
Correct. It describes the generic format of a URI. It then describes
several particular schemes, among them the 'file' scheme. It defines the
file scheme to use file://<host>/<path>, which is compatible with the
generic 'net_path' format.
> RFC2396 says file://<host>/<path> and file:/<path> are both ok.
Where does it say so. AFAICT it adds another possible format (the
'abs_path' version) to the *generic* URI format. For any particular
scheme a subset of that generic format is typically chosen. For the
'file' scheme that is done in RFC1738. Where does RFC2396 say that the
file scheme is extended to make use of the new generic format option?
> Its wrong to ignore abs_path in a document that should be trying to
> clear up the issue.
>> that would be in direct conflict with the current state of the RFC
>> at the
>>IETF (unless someone can point to an RFC overriding 1738 on the matter
>>of the "file" protocol description).
> RFC1738 doesnt address abs_path, so its not correct to judge the
> validity of file:/ against it.
But RFC1738 defines the file scheme.
> RFC 2396 addresses both net_path and abs_path so i think it should be
> seen as a more relevant document.
Where does RFC2396 address file (and not only the generic framework)?
Joerg Barfurth Sun Microsystems - Desktop - Hamburg
>>>>>>>>>>>>>>>>>> using std::disclaimer <<<<<<<<<<<<<<<<<<<<<<<
Software Engineer joerg.barfurth at sun.com
OpenOffice.org Configuration http://util.openoffice.org
More information about the xdg