OpenSSL is based on the excellent SSLeay library developed by Eric A. Young and Tim J. Hudson. The OpenSSL toolkit is licensed under an Apache-style licence, which basically means that you are free to get and use it for commercial and non-commercial purposes subject to some simple license conditions.
To encrypt a file:
$ openssl des3 -salt -in file.log -out file.des3The above will prompt for a password, or you can put it in with a -k option, assuming you’re on a trusted server.
enter des-ede3-cbc encryption password:
Verifying - enter des-ede3-cbc encryption password:
To Decrypt: openssl des3 -d -salt -in file.des3 -out file.txt -k mypassword
2 comments:
When decrypting, you shouldn't enter the password via the command line. It can be seen plain text by anyone standing around and will also be logged in .bash_history.
If you just run "openssl des3 -d -salt -in file.des3 -out file.txt" you'll be prompted for the password safely.
nice
Post a Comment