You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@santuario.apache.org by Lyudmila Balakireva <lu...@lanl.gov> on 2005/03/22 17:17:31 UTC
base64 transform
Hello,
I have problem "java.io.IOException.Stream closed" with Base64 transform (
I downloaded latest code) .
The Base64 Transform is second after Xpath Transform.
Please, help Luda
The code snipet:
Transforms transforms = new
Transforms(doc);
XPathContainer xpath = new XPathContainer(doc);
String xp1 =
"ancestor-or-self::didl:Resource[@encoding]";
xpath.setXPathNamespaceContext("didl",DIDL_NS);
xpath.setXPath(xp1);
transforms.addTransform(Transforms.TRANSFORM_XPATH,
xpath.getElementPlusReturns());
transforms.addTransform(Transforms.TRANSFORM_BASE64_DECODE);
xmlSig.addDocument(refurl, transforms,
Constants.ALGO_ID_DIGEST_SHA1);
The error:
org.apache.xml.security.signature.XMLSignatureException: Stream closed
[java] Original Exception was
org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
closed
[java] Original Exception was
org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
closed
[java] Original Exception was
org.apache.xml.security.signature.XMLSignatureException: Stream closed
[java] Original Exception was
org.apache.xml.security.transforms.TransformationException: Stream closed
[java] Original Exception was java.io.IOException: Stream closed
[java] at
org.apache.xml.security.signature.XMLSignature.sign(Unknown Source)
Re: base64 transform
Posted by Raul Benito <ra...@gmail.com>.
Can you post a bug report in bugzilla, I'm not going to work on it
immediately and I don't want to get it lost in my big heap of
mails(And latter I can give you credit for help).
You can use this URL, for writing it:
http://issues.apache.org/bugzilla/enter_bug.cgi?product=Security
Regards,
On Tue, 22 Mar 2005 17:37:16 +0100, Raul Benito
<ra...@gmail.com> wrote:
> Ok,
> Then I need a test case that I can compile myself and do the test
> myself(it can be either a jar or a .java).
>
> Regards,
>
>
> On Tue, 22 Mar 2005 09:31:10 -0700, Lyudmila Balakireva <lu...@lanl.gov> wrote:
> > Yes,
> > Thank you
> > At 05:18 PM 3/22/2005 +0100, you wrote:
> > >excuse me, which version of xml-sec are you using?
> > >Is the 1.2.1?
> > >
> > >Regards,
> > >
> > >
> > >On Tue, 22 Mar 2005 09:17:31 -0700, Lyudmila Balakireva <lu...@lanl.gov>
> > >wrote:
> > > > Hello,
> > > > I have problem "java.io.IOException.Stream closed" with Base64 transform (
> > > > I downloaded latest code) .
> > > >
> > > > The Base64 Transform is second after Xpath Transform.
> > > >
> > > > Please, help Luda
> > > >
> > > > The code snipet:
> > > >
> > > > Transforms transforms = new
> > > > Transforms(doc);
> > > >
> > > > XPathContainer xpath = new XPathContainer(doc);
> > > > String xp1 =
> > > > "ancestor-or-self::didl:Resource[@encoding]";
> > > > xpath.setXPathNamespaceContext("didl",DIDL_NS);
> > > > xpath.setXPath(xp1);
> > > > transforms.addTransform(Transforms.TRANSFORM_XPATH,
> > > > xpath.getElementPlusReturns());
> > > > transforms.addTransform(Transforms.TRANSFORM_BASE64_DECODE);
> > > > xmlSig.addDocument(refurl, transforms,
> > > > Constants.ALGO_ID_DIGEST_SHA1);
> > > >
> > > > The error:
> > > >
> > > > org.apache.xml.security.signature.XMLSignatureException: Stream closed
> > > > [java] Original Exception was
> > > > org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> > > > closed
> > > > [java] Original Exception was
> > > > org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> > > > closed
> > > > [java] Original Exception was
> > > > org.apache.xml.security.signature.XMLSignatureException: Stream closed
> > > > [java] Original Exception was
> > > > org.apache.xml.security.transforms.TransformationException: Stream closed
> > > > [java] Original Exception was java.io.IOException: Stream closed
> > > > [java] at
> > > > org.apache.xml.security.signature.XMLSignature.sign(Unknown Source)
> > > >
> > > >
> > >
> > >
> > >--
> > >http://r-bg.com
> >
> >
>
> --
> http://r-bg.com
>
--
http://r-bg.com
Re: base64 transform
Posted by Raul Benito <ra...@gmail.com>.
Ok,
Then I need a test case that I can compile myself and do the test
myself(it can be either a jar or a .java).
Regards,
On Tue, 22 Mar 2005 09:31:10 -0700, Lyudmila Balakireva <lu...@lanl.gov> wrote:
> Yes,
> Thank you
> At 05:18 PM 3/22/2005 +0100, you wrote:
> >excuse me, which version of xml-sec are you using?
> >Is the 1.2.1?
> >
> >Regards,
> >
> >
> >On Tue, 22 Mar 2005 09:17:31 -0700, Lyudmila Balakireva <lu...@lanl.gov>
> >wrote:
> > > Hello,
> > > I have problem "java.io.IOException.Stream closed" with Base64 transform (
> > > I downloaded latest code) .
> > >
> > > The Base64 Transform is second after Xpath Transform.
> > >
> > > Please, help Luda
> > >
> > > The code snipet:
> > >
> > > Transforms transforms = new
> > > Transforms(doc);
> > >
> > > XPathContainer xpath = new XPathContainer(doc);
> > > String xp1 =
> > > "ancestor-or-self::didl:Resource[@encoding]";
> > > xpath.setXPathNamespaceContext("didl",DIDL_NS);
> > > xpath.setXPath(xp1);
> > > transforms.addTransform(Transforms.TRANSFORM_XPATH,
> > > xpath.getElementPlusReturns());
> > > transforms.addTransform(Transforms.TRANSFORM_BASE64_DECODE);
> > > xmlSig.addDocument(refurl, transforms,
> > > Constants.ALGO_ID_DIGEST_SHA1);
> > >
> > > The error:
> > >
> > > org.apache.xml.security.signature.XMLSignatureException: Stream closed
> > > [java] Original Exception was
> > > org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> > > closed
> > > [java] Original Exception was
> > > org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> > > closed
> > > [java] Original Exception was
> > > org.apache.xml.security.signature.XMLSignatureException: Stream closed
> > > [java] Original Exception was
> > > org.apache.xml.security.transforms.TransformationException: Stream closed
> > > [java] Original Exception was java.io.IOException: Stream closed
> > > [java] at
> > > org.apache.xml.security.signature.XMLSignature.sign(Unknown Source)
> > >
> > >
> >
> >
> >--
> >http://r-bg.com
>
>
--
http://r-bg.com
Re: base64 transform
Posted by Lyudmila Balakireva <lu...@lanl.gov>.
Yes,
Thank you
At 05:18 PM 3/22/2005 +0100, you wrote:
>excuse me, which version of xml-sec are you using?
>Is the 1.2.1?
>
>Regards,
>
>
>On Tue, 22 Mar 2005 09:17:31 -0700, Lyudmila Balakireva <lu...@lanl.gov>
>wrote:
> > Hello,
> > I have problem "java.io.IOException.Stream closed" with Base64 transform (
> > I downloaded latest code) .
> >
> > The Base64 Transform is second after Xpath Transform.
> >
> > Please, help Luda
> >
> > The code snipet:
> >
> > Transforms transforms = new
> > Transforms(doc);
> >
> > XPathContainer xpath = new XPathContainer(doc);
> > String xp1 =
> > "ancestor-or-self::didl:Resource[@encoding]";
> > xpath.setXPathNamespaceContext("didl",DIDL_NS);
> > xpath.setXPath(xp1);
> > transforms.addTransform(Transforms.TRANSFORM_XPATH,
> > xpath.getElementPlusReturns());
> > transforms.addTransform(Transforms.TRANSFORM_BASE64_DECODE);
> > xmlSig.addDocument(refurl, transforms,
> > Constants.ALGO_ID_DIGEST_SHA1);
> >
> > The error:
> >
> > org.apache.xml.security.signature.XMLSignatureException: Stream closed
> > [java] Original Exception was
> > org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> > closed
> > [java] Original Exception was
> > org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> > closed
> > [java] Original Exception was
> > org.apache.xml.security.signature.XMLSignatureException: Stream closed
> > [java] Original Exception was
> > org.apache.xml.security.transforms.TransformationException: Stream closed
> > [java] Original Exception was java.io.IOException: Stream closed
> > [java] at
> > org.apache.xml.security.signature.XMLSignature.sign(Unknown Source)
> >
> >
>
>
>--
>http://r-bg.com
Re: base64 transform
Posted by Raul Benito <ra...@gmail.com>.
excuse me, which version of xml-sec are you using?
Is the 1.2.1?
Regards,
On Tue, 22 Mar 2005 09:17:31 -0700, Lyudmila Balakireva <lu...@lanl.gov> wrote:
> Hello,
> I have problem "java.io.IOException.Stream closed" with Base64 transform (
> I downloaded latest code) .
>
> The Base64 Transform is second after Xpath Transform.
>
> Please, help Luda
>
> The code snipet:
>
> Transforms transforms = new
> Transforms(doc);
>
> XPathContainer xpath = new XPathContainer(doc);
> String xp1 =
> "ancestor-or-self::didl:Resource[@encoding]";
> xpath.setXPathNamespaceContext("didl",DIDL_NS);
> xpath.setXPath(xp1);
> transforms.addTransform(Transforms.TRANSFORM_XPATH,
> xpath.getElementPlusReturns());
> transforms.addTransform(Transforms.TRANSFORM_BASE64_DECODE);
> xmlSig.addDocument(refurl, transforms,
> Constants.ALGO_ID_DIGEST_SHA1);
>
> The error:
>
> org.apache.xml.security.signature.XMLSignatureException: Stream closed
> [java] Original Exception was
> org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> closed
> [java] Original Exception was
> org.apache.xml.security.signature.ReferenceNotInitializedException: Stream
> closed
> [java] Original Exception was
> org.apache.xml.security.signature.XMLSignatureException: Stream closed
> [java] Original Exception was
> org.apache.xml.security.transforms.TransformationException: Stream closed
> [java] Original Exception was java.io.IOException: Stream closed
> [java] at
> org.apache.xml.security.signature.XMLSignature.sign(Unknown Source)
>
>
--
http://r-bg.com