RE: Prefix rewriting considerations

> Don't you get such qname problems as well with rewriting prefixes to
> "ns$i" or to base64(hash(ns-uri))?

Yes, but we're handling that now (to the extent we can). The point is, what
does "simplifying" the other cases buy us if we still have to address the
prefixes anyway?

> I mean, this is about
> canonicalization, hence direct input to digest computation. If you'd do
> a prefix rewrite in *any* way, such references to "xsd:string" will be
> broken in the c14n'ed XML.

Unless you rewrite them too.

> Regarding attributes: you'll only need prefixes if an attribute is from
> a different namespace than its element (rare case).

It's not really that rare (xsi:type being one obvious case, SOAP being
another).

> Then you can define
> an arbitrary prefix (e.g. using the "ns$i" approach) at that element,
> which thus is only relevant for that single attribute(s) at this
> particular element. Advantage is that you don't have to deal with issues
> of identical prefixes mapping to different namespace uris.

The point is that it defeats the simplification you're suggesting exists
when the exceptions are quite common.

-- Scott

Received on Tuesday, 13 April 2010 19:41:08 UTC