Create a file with your secret contents
$ cat > confidential.txtEncrypt it, and supply an encryption password
Here is my secret!
<ctrl-d>
$ openssl enc -aes-256-cbc -salt -in ./confidential.txt -out ./confidential.txt.encYou just can't read the file now... its safe to send over an unencrypted connection.
enter aes-256-cbc encryption password:
Verifying - enter aes-256-cbc encryption password:
$ cat ./confidential.txt.encTo decrypt, you'll need to agree on the encryption password with your third party, or somehow have sent it securely already.
Salted__??(?*???q^s????_ۂꠤ?~|~#?`+@
$ openssl enc -d -aes-256-cbc -in ./confidential.txt.enc
enter aes-256-cbc decryption password:
Here is my secret!
No comments:
Post a Comment