Thursday, June 28, 2012

Encrypt all files in folder using openssl

#!/bin/bash
FILENAMES=$(ls -tr /home/oracle/scripts/encauto/files
for FILES in ${FILENAMES}
do
export FILES
openssl aes-256-cbc -a -salt -in /home/oracle/scripts/encauto/files/${FILES} -out /home/oracle/scripts/encauto/files/${FILES}.enc -k ninjas



done

0 comments:

Post a Comment