You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@santuario.apache.org by co...@apache.org on 2012/02/09 13:17:12 UTC
svn commit: r1242292 - in /santuario/xml-security-java/trunk: CHANGELOG.txt
src/main/java/org/apache/xml/security/signature/XMLSignatureInput.java
Author: coheigea
Date: Thu Feb 9 12:17:12 2012
New Revision: 1242292
URL: http://svn.apache.org/viewvc?rev=1242292&view=rev
Log:
[SANTUARIO-296] - XMLSignatureInput fails with an IOException if constructed on a BufferedInputStream
Modified:
santuario/xml-security-java/trunk/CHANGELOG.txt
santuario/xml-security-java/trunk/src/main/java/org/apache/xml/security/signature/XMLSignatureInput.java
Modified: santuario/xml-security-java/trunk/CHANGELOG.txt
URL: http://svn.apache.org/viewvc/santuario/xml-security-java/trunk/CHANGELOG.txt?rev=1242292&r1=1242291&r2=1242292&view=diff
==============================================================================
--- santuario/xml-security-java/trunk/CHANGELOG.txt (original)
+++ santuario/xml-security-java/trunk/CHANGELOG.txt Thu Feb 9 12:17:12 2012
@@ -1,6 +1,7 @@
Changelog for "Apache xml-security" <http://santuario.apache.org/>
New in v1.5.1-SNAPSHOT:
+ Fixed SANTUARIO-296 - XMLSignatureInput fails with an IOException if constructed on a BufferedInputStream
Fixed SANTUARIO-298 - Xalan is still a required dependency
Fixed SANTUARIO-299 - StringIndexOutOfBoundsException is thrown during reference verification (if URI = "#")
Fixed SANTUARIO-297 - Exceptions should use a JDK exception cause mechanism
Modified: santuario/xml-security-java/trunk/src/main/java/org/apache/xml/security/signature/XMLSignatureInput.java
URL: http://svn.apache.org/viewvc/santuario/xml-security-java/trunk/src/main/java/org/apache/xml/security/signature/XMLSignatureInput.java?rev=1242292&r1=1242291&r2=1242292&view=diff
==============================================================================
--- santuario/xml-security-java/trunk/src/main/java/org/apache/xml/security/signature/XMLSignatureInput.java (original)
+++ santuario/xml-security-java/trunk/src/main/java/org/apache/xml/security/signature/XMLSignatureInput.java Thu Feb 9 12:17:12 2012
@@ -238,9 +238,6 @@ public class XMLSignatureInput {
*/
public InputStream getOctetStream() throws IOException {
if (inputOctetStreamProxy != null) {
- if (inputOctetStreamProxy.markSupported()) {
- inputOctetStreamProxy.reset();
- }
return inputOctetStreamProxy;
}
@@ -488,9 +485,6 @@ public class XMLSignatureInput {
c14nizer.setWriter(diOs);
c14nizer.engineCanonicalize(this);
} else {
- if (inputOctetStreamProxy.markSupported()) {
- inputOctetStreamProxy.reset();
- }
byte[] buffer = new byte[4 * 1024];
int bytesread = 0;
while ((bytesread = inputOctetStreamProxy.read(buffer)) != -1) {
@@ -513,15 +507,9 @@ public class XMLSignatureInput {
if (inputOctetStreamProxy == null) {
return null;
}
- if (inputOctetStreamProxy.markSupported()) {
- inputOctetStreamProxy.reset();
- bytes = JavaUtils.getBytesFromStream(inputOctetStreamProxy);
- return bytes;
- } else {
- bytes = JavaUtils.getBytesFromStream(inputOctetStreamProxy);
- inputOctetStreamProxy.close();
- return bytes;
- }
+ bytes = JavaUtils.getBytesFromStream(inputOctetStreamProxy);
+ inputOctetStreamProxy.close();
+ return bytes;
}
/**