Symmetric encrypt many files (batch mode)

Ryan Sawhill ryan at
Mon Jan 5 06:33:03 CET 2015

Assuming you want to encrypt every single file in a directory tree, your
best bet would be to use the find command. Something like this:

find /SomeDirectory -type f -exec gpg2 --batch --cipher-algo AES256
--force-mdc --symmetric --passphrase-file /FILE -o {}.gpg {} \;

The above will save each file with the same name + an extension of ".gpg".
The cipher-algo & force-mdc options aren't required of course. Just a
personal recommendation.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/attachments/20150105/16d0a1a2/attachment.html>

More information about the Gnupg-users mailing list