'file' URI scheme

Luke -Jr luke at dashjr.org
Sun Mar 30 15:14:46 PDT 2008


On Sunday 30 March 2008, Thiago Macieira wrote:
> >file:///etc;foo/config;bar/some.conf;hi
>
> What parameters?

Section 3.3 of RFC 2396 (Uniform Resource Identifiers (URI): Generic Syntax)

> That URL above maps to the file: 
>
> 	/etc;foo/config;bar/some.conf;hi
>
> I doubt that file exists in your system. If there's any such thing as
> parameters, they must be handled by the open(2) system call.

Path component parameters are defined in the URI standard, but (AFAIK) do not 
exist in any POSIX standard-- nor does Linux itself provide support for URIs, 
as far as I am aware.

The URI RFC, while it does not define the application of parameters in file 
URIs, does define that "The parameters are not significant to the parsing of 
relative references.", which I read as meaning that "..;foo/bar" acts the 
same as "../bar". Following this logic, it would seem the "proper" thing to 
do in a file URI is to ignore unrecognized parameters and map my example 
to /etc/config/some.conf

Luke


More information about the xdg mailing list