W3C home > Mailing lists > Public > w3c-rdfcore-wg@w3.org > September 2003

can we leave relative URI references unconstrained? (no, don't think so after all)

From: Dan Connolly <connolly@w3.org>
Date: Tue, 16 Sep 2003 11:38:48 -0500
To: w3c-rdfcore-wg@w3.org
Message-Id: <1063730328.5532.219.camel@dirk.dm93.org>

Thinking out loud...


   <Doodad rdf:about="very silly ## reference"/>

Is that an RDF document? OK, after you add
the namespaces... is it an RDF document?

Consulting our shiny new drafts... we find...

which takes us to

which says
  "An attribute ·string-value· interpreted as an RDF URI reference."

hmm... "interpreted as" doesn't seem to change the fact that
the syntax allows any string. So far, no clear evidence
to rule out this document...

Now to the relevant grammar actions...

If there is an attribute a with a.URI == rdf:about then e.subject :=
uri(identifier := resolve(e, a.string-value)).

then back to 6.3.3 Grammar Action Notation
to see how resolve() works...

then down to  5.3 Resolving URIs

"Relative URI references are resolved into RDF URI references according
to the algorithm specified in XML Base [XML-BASE] (and RFC 2396)."

er... but that algorithm takes an ASCII string as input,
and a limited form of ASCII string... it doesn't take
any old unicode string.

So this appears to be a conforming RDF document whose abstract syntax
is incompletely specified... er... no, in section 5.5 Conformance,
"RDF document" is specified as something that is serialized from
an RDF graph, not somethignt that matches this grammar(!).

By that definition, since there's no RDF URI Reference
that can result from resolving "very silly ## reference",
this isn't an RDF document.

I took an action (2003-09-12#4) to propose to relax that
constraint, but now that I see how RDF document is defined,
I don't think that's wise.

I suppose it would be sorta rude to just stop here and hit
send... let's pop back to the motivating issue... ah yes,
% in URIs...

so the relevant test case looks more like

   <Doodad rdf:about="somewhat%silly%reference"/>

let's look at 6.4 RDF URI References again...

we can't delete the % from that para; if we did, then

  <rdf:RDF xml:base="http://example/">
   <Doodad rdf:about="quite%2Fordinary%2Freference"/>

would turn into the URI http://example/quite%252Fordinary%252Freference
which is clearly not what we want; by design, it remains

I suggest this last case be put in the test suite in response
to the 26Aug comment.

Gosh... I see more issues... control characters and such
in the "escaping % in RDF URI references" thread.

Seems clear to me that our spec doesn't allow control characters;
how would you find a unicode string U' where utf8-%%-encode(U')
is a plain old ASCII absolute URI reference with optional fragid
while U' has control characters in it? Ew... now I see... yes,
they are allowed by our current draft.

Ugh... time to study namespaces 1.1... I'm losing energy at
this point. I think I'll hit send now. Perhaps I'll find
time/energy to pick it up again later.

Dan Connolly, W3C http://www.w3.org/People/Connolly/
Received on Tuesday, 16 September 2003 12:38:49 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:54:08 UTC