[xmlsec] Reference URI: ID vs CDATA

Aleksey Sanin aleksey at aleksey.com
Tue Sep 16 09:03:06 PDT 2003


>Visa has specified this attribute as 'CDATA' not 'ID'. In practice, the PARes messages contain characters invalid for 'ID' type and this is why verification fails sometimes. 
>  
>
And I forgot to say that I am not sure how can you reference CDATA 
attribute using "id('AAA')"
XPath function or "#AAA" XPointer expression. May be I am missing 
something but IMHO this is
just impossible:

    XPath
       http://www.w3.org/TR/xpath#section-Node-Set-Functions
       http://www.w3.org/TR/xpath#unique-id

       The *id* function selects elements by their unique ID (see 
[*5.2.1 Unique IDs*]).
       ...
       An element node may have a unique identifier (ID). This is the 
value of the attribute
       that is declared in the DTD as type |ID|.

    XPointer
      http://www.w3.org/TR/xptr-framework/#shorthand

      The identifiers of an element are determined as follows:

   1.

      If an element information item has an attribute information item
      among its *[attributes]*
      that is a schema-determined ID, then it is identified by the value
      of that attribute information
      item's *[schema normalized value]* property;

   2.

      If an element information item has an element information item
      among its *[children]*
      that is a schema-determined ID, then it is identified by the value
      of that element information
      item's *[schema normalized value]* property;

   3.

      If an element information item has an attribute information item
      among its *[attributes]*
      that is a DTD-determined ID, then it is identified by the value of
      that attribute information
      item's *[normalized value]* property.

   4.

      An element information item may also be identified by an
      externally-determined ID value


There is an option 4) in XPointer specification that says "do whatever 
you want" but I doubt that
you want to have an interoperable specification based on this it.

Aleksey


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.aleksey.com/pipermail/xmlsec/attachments/20030916/f1a2d91e/attachment.htm


More information about the xmlsec mailing list