You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by sd...@apache.org on 2016/06/16 07:14:13 UTC

commons-crypto git commit: CRYPTO-71: Hide the implementation of OpensslCipher

Repository: commons-crypto
Updated Branches:
  refs/heads/master 4afa1ec81 -> 271b37f74


CRYPTO-71: Hide the implementation of OpensslCipher


Project: http://git-wip-us.apache.org/repos/asf/commons-crypto/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-crypto/commit/271b37f7
Tree: http://git-wip-us.apache.org/repos/asf/commons-crypto/tree/271b37f7
Diff: http://git-wip-us.apache.org/repos/asf/commons-crypto/diff/271b37f7

Branch: refs/heads/master
Commit: 271b37f74cd196192a50a802a6a0bfe1908775ed
Parents: 4afa1ec
Author: kexianda <xi...@intel.com>
Authored: Thu Jun 16 15:05:11 2016 +0800
Committer: Sun Dapeng <sd...@apache.org>
Committed: Thu Jun 16 15:05:11 2016 +0800

----------------------------------------------------------------------
 src/main/java/org/apache/commons/crypto/cipher/Openssl.java        | 2 +-
 src/main/java/org/apache/commons/crypto/cipher/OpensslNative.java  | 2 +-
 .../org/apache/commons/crypto/stream/AbstractCipherStreamTest.java | 1 -
 3 files changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-crypto/blob/271b37f7/src/main/java/org/apache/commons/crypto/cipher/Openssl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/crypto/cipher/Openssl.java b/src/main/java/org/apache/commons/crypto/cipher/Openssl.java
index 1d0e441..2837761 100644
--- a/src/main/java/org/apache/commons/crypto/cipher/Openssl.java
+++ b/src/main/java/org/apache/commons/crypto/cipher/Openssl.java
@@ -36,7 +36,7 @@ import org.apache.commons.crypto.utils.Utils;
  * OpenSSL cryptographic wrapper using JNI. Currently only AES-CTR is supported.
  * It's flexible to add other crypto algorithms/modes.
  */
-public final class Openssl {
+final class Openssl {
     private static final Log LOG = LogFactory.getLog(Openssl.class.getName());
 
     // Mode constant defined by Openssl JNI

http://git-wip-us.apache.org/repos/asf/commons-crypto/blob/271b37f7/src/main/java/org/apache/commons/crypto/cipher/OpensslNative.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/crypto/cipher/OpensslNative.java b/src/main/java/org/apache/commons/crypto/cipher/OpensslNative.java
index 7b4f5a5..0be5828 100644
--- a/src/main/java/org/apache/commons/crypto/cipher/OpensslNative.java
+++ b/src/main/java/org/apache/commons/crypto/cipher/OpensslNative.java
@@ -23,7 +23,7 @@ import java.nio.ByteBuffer;
  * JNI interface of {@link Openssl} implementation. The native method in this
  * class is defined in OpensslNative.h (generated by javah).
  */
-public class OpensslNative {
+class OpensslNative {
 
   /**
    * The private constructor of {@Link OpensslNative}.

http://git-wip-us.apache.org/repos/asf/commons-crypto/blob/271b37f7/src/test/java/org/apache/commons/crypto/stream/AbstractCipherStreamTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/crypto/stream/AbstractCipherStreamTest.java b/src/test/java/org/apache/commons/crypto/stream/AbstractCipherStreamTest.java
index a9d6fef..1a494db 100644
--- a/src/test/java/org/apache/commons/crypto/stream/AbstractCipherStreamTest.java
+++ b/src/test/java/org/apache/commons/crypto/stream/AbstractCipherStreamTest.java
@@ -313,7 +313,6 @@ public abstract class AbstractCipherStreamTest {
 
     @Test
     public void testReadWrite() throws Exception {
-        Assert.assertEquals(null, Openssl.getLoadingFailureReason());
         doReadWriteTest(0, jceCipherClass, jceCipherClass, iv);
         doReadWriteTest(0, opensslCipherClass, opensslCipherClass, iv);
         doReadWriteTest(count, jceCipherClass, jceCipherClass, iv);