-
-
Save dymx101/1a97d9f4215ce51e9630ad66cc1a3286 to your computer and use it in GitHub Desktop.
Encrypt/Decrypt Files Using OpenSSL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# encrypt | |
openssl enc -in test.txt -aes-256-cbc -pass pass:mypass -out test.txt.enc | |
# decrypt | |
openssl enc -in test.txt.enc -d -aes-256-cbc -pass pass:mypass -out test.txt | |
# valid password sources (as of OpenSSL 1.1.1, see 'man openssl' for more recent info): | |
# -pass pass:mypass | |
# -pass env:somevar | |
# -pass file:somepathname | |
# -pass fd:number | |
# -pass stdin |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment