EncryptTool { public static SecretKey generateKeyEncryptionKey() throws Exception { String jceAlgorithmName = "DESede"; KeyGenerator keyGenerator = KeyGenerator.getInstance(jceAlgorithmName); SecretKey kek = keyGenerator.generateKey(); return kek; }  static SecretKey generateKeyEncryptionKey(); static SecretKey generateDataEncryptionKey();  }
@Test public void testGenerateKeyEncryptionKey() throws Exception { assertEquals(EncryptTool.generateKeyEncryptionKey().getClass().getName(),"com.sun.crypto.provider.DESedeKey"); }