When you have sensitive data that you need to transmit but want to make it easy to encrypt and decrypt it, use some standard tools to get the job done!
When sending sensitive material across the globe, be it via email, dropbox or any other file sharing utility you probably want to enrcrypt your data before sending it.
Here is an alternative to do just that; tar the files and encrypt it with OpenSSL!
Encrypting Your File
tar and gzip the file, then encrypt it using des3 and a secret key. Changing #YOUR PASSWORD# to your super strong secret password that no one else knows.
1 |
tar cvzf - sensitive_file.document | openssl des3 -salt -k #YOUR PASSWORD# | dd of=encrypted_sensitive_file |
It is that simple!
When received on the other end its essentially calling the commands in reverse order.
1 |
dd if=encrypted_sensitive_file |openssl des3 -d -k #YOUR PASSWORD# |tar xvzf - |
9 comments for “Encrypting a tar or gz (gzip) File with OpenSSL”