AesCipher cipher = createCipher(KeyGenerator.OPEN_SSL);
run(cipher);
}
private AesCipher createCipher(KeyGenerator type) {
AesCipher cipher = BouncyCastleAesProvider.getInstance().newCipher(type);
cipher.setPassphrase(PASSPHRASE);
cipher.setKeyLength(KEY_LENGTH);
cipher.setSalt(SALT);
cipher.setIterationCount(IC);
return cipher;
}