Created
May 3, 2020 11:54
-
-
Save abel0b/aec5065a90b52a022aa92998466ac273 to your computer and use it in GitHub Desktop.
Cheatsheet encrypt stuff with gpg
This file contains hidden or 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
# man gpg | |
# configuration in ~/.gnupg | |
# generate gpg keypair with default options | |
gpg --gen-key | |
# or use dialog | |
gpg --full-generate-key | |
# import a key | |
gpg --import-key alice.key | |
# search a key on mit key server | |
gpg --keyserver pgp.mit.edu --search-keys [email protected] | |
# export my key | |
gpg --output bob.key --armor --export [email protected] | |
# encrypt a file | |
gpg --encrypt --recipent [email protected] attack-plan.txt | |
# decrypt a file | |
gpg --decrypt attack-plan.txt.gpg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment