[xmlsec] Using XPath

Gregor Ibic gregor.ibic at intelicom.si
Fri Nov 1 07:04:05 PST 2002


How can I apply this path to the xml doc? I always get an Expression Error.

count(ancestor-or-self::dsig:Signature | here()/ancestor::dsig:Signature[1])
> count(ancestor-or-self::dsig:Signature)

or

not(ancestor-or-self::dsig:Signature)

or

not(ancestor-or-self::Signature)

**************************************
<?xml version="1.0" encoding="UTF-8" ?>
<Request>
<DataObject Id="object">abcšd</DataObject>
<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">
  <SignedInfo>
    <CanonicalizationMethod
Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315" />
    <SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"
/>
    <Reference URI="#object">
      <DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
      <DigestValue></DigestValue>
    </Reference>
  </SignedInfo>
  <SignatureValue>
  </SignatureValue>
  <KeyInfo>
    <KeyName></KeyName>
  </KeyInfo>
</Signature>
</Request>

**************************************

Regards,
Gregor




More information about the xmlsec mailing list