diff options
Diffstat (limited to 'pdf-as-cli/src/test/java/at/gv/egiz/pdfas')
-rw-r--r-- | pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java b/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java index 8766a5bd..e14b8ca0 100644 --- a/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java +++ b/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java @@ -30,7 +30,8 @@ import java.util.ArrayList; import java.util.Iterator; import java.util.List; -import sun.misc.IOUtils; +import org.apache.commons.io.IOUtils; + import at.gv.egiz.pdfas.common.settings.ISettings; import at.gv.egiz.pdfas.lib.api.ByteArrayDataSink; import at.gv.egiz.pdfas.lib.api.ByteArrayDataSource; @@ -87,8 +88,7 @@ public class SignaturProfileTest { } } - byte[] input = IOUtils.readFully(new FileInputStream(sourcePDF), - -1, true); + byte[] input = IOUtils.toByteArray(new FileInputStream(sourcePDF)); IPlainSigner signer = new PAdESSignerKeystore(KS_FILE, KS_ALIAS, KS_PASS, KS_KEY_PASS, KS_TYPE); @@ -114,8 +114,7 @@ public class SignaturProfileTest { fos.close(); } - byte[] inputPDFA = IOUtils.readFully(new FileInputStream(sourcePDFA), - -1, true); + byte[] inputPDFA = IOUtils.toByteArray(new FileInputStream(sourcePDFA)); Iterator<String> itPDFAProfiles = signaturePDFAProfiles.iterator(); while (itPDFAProfiles.hasNext()) { |