Re: namespace question

At 15:38 7/10/00 -0700, Kevin Regan wrote:
 >I've been attempting to implement the latest XML Signature and C14N
 >specifications.  However, I have a few questions.

I'm sure John will be able to answer more authoratively, but an easy answer
and question:

 >It seems that when computing the canonicalized form of an Element
 >representing a sub-tree of an XML document, the namespace declarations of
 >all the parents of the given element (all the way to the Document root
 >element) are included in that element as well as all of that Element's
 >children (unless overridden at some point).

Yes.

   An element E has namespace nodes that represent its namespace
   declarations, any namespace declarations made by its ancestor that
   have not been overridden in E's declaration, the default namespace if
   it is non-empty, and the declaration of the prefix xml. 
   http://www.w3.org/TR/2000/WD-xml-c14n-20000710

This is done such that you can move a signature and ensure its namespace
context is taken with it.

 >  What I'm not exactly clear on
 >is if this applies to the actual Signature element for the signature being
 >created.

I don't quite follow...

 >I don't think that it does (I don't believe that you need to
 >look at the parent elements of the Signature element to determine their
 >namespace declarations)?  Is this correct?  If not, wouldn't it mean that
 >the insertion point for the Signature element must be known in advance so
 >that these declarations can be obtained?  Are there any differences for
 >detached, enveloped, or enveloping signatures?

What do you mean known in advance?
 

_________________________________________________________
Joseph Reagle Jr.   
W3C Policy Analyst                mailto:reagle@w3.org
IETF/W3C XML-Signature Co-Chair   http://www.w3.org/People/Reagle/

Received on Wednesday, 12 July 2000 14:39:19 UTC