ringa_lee
使用 CipherOutputStream
Cipher cipher = Cipher.getInstance("AES"); cipher.init(Cipher.ENCRYPT_MODE, key); InputStream is = new FileInputStream(file); CipherOutputStream out = new CipherOutputStream(new FileOutputStream(dest), cipher) IOUtils.copyLarge(is, out);
使用 CipherOutputStream