src/java.base/share/classes/com/sun/crypto/provider/KeyProtector.java
changeset 51504 c9a3e3cac9c7
parent 51293 53c3b460503c
child 59158 438337c846fb
--- a/src/java.base/share/classes/com/sun/crypto/provider/KeyProtector.java	Thu Aug 23 10:52:27 2018 +0200
+++ b/src/java.base/share/classes/com/sun/crypto/provider/KeyProtector.java	Thu Aug 23 11:37:14 2018 +0100
@@ -310,14 +310,14 @@
         Cipher cipher;
         try {
             sKey = new PBEKey(pbeKeySpec, "PBEWithMD5AndTripleDES", false);
-        pbeKeySpec.clearPassword();
+            pbeKeySpec.clearPassword();
 
-        // seal key
-        PBEWithMD5AndTripleDESCipher cipherSpi;
-        cipherSpi = new PBEWithMD5AndTripleDESCipher();
-        cipher = new CipherForKeyProtector(cipherSpi, SunJCE.getInstance(),
-                                           "PBEWithMD5AndTripleDES");
-        cipher.init(Cipher.ENCRYPT_MODE, sKey, pbeSpec);
+            // seal key
+            PBEWithMD5AndTripleDESCipher cipherSpi;
+            cipherSpi = new PBEWithMD5AndTripleDESCipher();
+            cipher = new CipherForKeyProtector(cipherSpi, SunJCE.getInstance(),
+                                               "PBEWithMD5AndTripleDES");
+            cipher.init(Cipher.ENCRYPT_MODE, sKey, pbeSpec);
         } finally {
             if (sKey != null) sKey.destroy();
         }