How to encrypt a file in java using AES

53,748

Try using a CipherOutputStream and passing in a FileOutputStream. See http://www.java2s.com/Tutorial/Java/0490__Security/UsingCipherOutputStream.htm for a quick example, just use Cipher.getInstance("AES/CBC/PKCS5Padding") instead.

Share:
53,748

Related videos on Youtube

Princeyesuraj
Author by

Princeyesuraj

Updated on July 09, 2022

Comments

  • Princeyesuraj
    Princeyesuraj almost 2 years

    I need to know how to create an AES and using it to encrypt and decrypt a file in java.

Related