You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@santuario.apache.org by "Colm O hEigeartaigh (JIRA)" <ji...@apache.org> on 2011/07/16 18:17:59 UTC
[jira] [Updated] (SANTUARIO-273) xml:base attribute not processed
correctly in C14N11 canonicalization
[ https://issues.apache.org/jira/browse/SANTUARIO-273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Colm O hEigeartaigh updated SANTUARIO-273:
------------------------------------------
Fix Version/s: Java 1.5
Java 1.4.6
> xml:base attribute not processed correctly in C14N11 canonicalization
> ---------------------------------------------------------------------
>
> Key: SANTUARIO-273
> URL: https://issues.apache.org/jira/browse/SANTUARIO-273
> Project: Santuario
> Issue Type: Bug
> Components: Java
> Affects Versions: Java 1.4.4
> Environment: Windows 7 Professional
> Reporter: Daniel Granath
> Assignee: Colm O hEigeartaigh
> Labels: c14n11
> Fix For: Java 1.4.6, Java 1.5
>
> Attachments: CanonSubTree.java
>
>
> In version 1.4.4 it seems that the xml:base attribute is not processed correctly. I have modified the input in the sample org.apache.xml.security.samples.canonicalization.CanonSubTree to make it look like this:
> <?xml version="1.0" encoding="UTF-8"?>
> <Signature xmlns="http://www.w3.org/2000/09/xmldsig#"
> xml:base="http://www.acme.com/resources/">
> <SignedInfo xml:base="subresources/"><!-- comment inside -->
> <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="http://www.w3.org/TR/xml-stylesheet">
> <DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
> <DigestValue>60NvZvtdTB+7UnlLp/H24p7h4bs=</DigestValue>
> </Reference>
> </SignedInfo>
> <SignatureValue>
> fKMmy9GYF2s8rLFrZdVugTOFuWx19ccX7jh5HqFd4vMOY7LWAj52ykjSdvtW3fNY
> PPYGC4MFL19oPSId5GEsMtFMpGXB3XaCtoKjMCHQsN3+kom8YnGf7Ge1JNRcGty5
> 0UsoP6Asj47+QR7QECT64uoziha4WRDVyXjDrg24W+U=
> </SignatureValue>
> <KeyInfo>
> <KeyName>Lugh</KeyName>
> </KeyInfo>
> </Signature>
> The only changes are the xml:base attributes on the Signature and SignedInfo elements. The other change I've made is to use c14n11 (http://www.w3.org/2006/12/xml-c14n11).
> The output from the sample is:
> <SignedInfo xmlns="http://www.w3.org/2000/09/xmldsig#"
> xml:base="subresources/">
> <CanonicalizationMethod
> Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"></CanonicalizationMethod>
> <SignatureMethod
> Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"></SignatureMethod>
> <Reference URI="http://www.w3.org/TR/xml-stylesheet">
> <DigestMethod
> Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"></DigestMethod>
> <DigestValue>60NvZvtdTB+7UnlLp/H24p7h4bs=</DigestValue>
> </Reference>
> </SignedInfo>
> I would have expected the xml:base attribute to get the value
> "http://www.acme.com/resources/subresources/".
> I have also tested this against the latest source in the 1.4.x-fixes branch
> with the same result.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira