This commit is contained in:
parent
a0a7bd6596
commit
daeb5282a6
@ -3,7 +3,7 @@
|
||||
### Generate
|
||||
|
||||
```console
|
||||
$ gpg --full-gen-key
|
||||
gpg --full-gen-key
|
||||
```
|
||||
|
||||
### Basic usage
|
||||
@ -11,31 +11,31 @@ $ gpg --full-gen-key
|
||||
Signature sig mode:
|
||||
|
||||
```console
|
||||
$ gpg --detach-sign file.ext
|
||||
gpg --detach-sign file.ext
|
||||
```
|
||||
|
||||
Signature asc mode:
|
||||
|
||||
```console
|
||||
$ gpg --armor --sign file.ext
|
||||
gpg --armor --sign file.ext
|
||||
```
|
||||
|
||||
Verify:
|
||||
|
||||
```console
|
||||
$ gpg --verify file.sig
|
||||
gpg --verify file.sig
|
||||
```
|
||||
|
||||
### My user-id
|
||||
|
||||
```console
|
||||
$ gpg -K
|
||||
gpg -K
|
||||
```
|
||||
|
||||
### All users-ids
|
||||
|
||||
```console
|
||||
$ gpg -k
|
||||
gpg -k
|
||||
```
|
||||
|
||||
### Copy Public Key
|
||||
@ -47,50 +47,50 @@ gpg --export --armor $(gpg -K --with-colons | awk -F: '/^sec/ { getline; print $
|
||||
### Copy Private key (Caution)
|
||||
|
||||
```console
|
||||
$ gpg --export-secret-keys -a <user-id> | xclip -sel clip
|
||||
gpg --export-secret-keys -a <user-id> | xclip -sel clip
|
||||
```
|
||||
|
||||
### Change password gpg
|
||||
|
||||
```console
|
||||
$ gpg --edit-key <user-id>
|
||||
gpg --edit-key <user-id>
|
||||
passwd
|
||||
```
|
||||
|
||||
### Debug gpg
|
||||
|
||||
```console
|
||||
$ dirmngr --debug-level guru
|
||||
dirmngr --debug-level guru
|
||||
```
|
||||
|
||||
### Import key:
|
||||
|
||||
```console
|
||||
$ gpg --recv-keys $esefingerprint
|
||||
gpg --recv-keys $esefingerprint
|
||||
```
|
||||
|
||||
### Import key from server:
|
||||
|
||||
```console
|
||||
$ gpg --recv-keys <user-id> --keyserver pgp.mit.edu
|
||||
gpg --recv-keys <user-id> --keyserver pgp.mit.edu
|
||||
```
|
||||
|
||||
### Export key 0:
|
||||
|
||||
```console
|
||||
$ gpg --export --armor <user-id> > public.key
|
||||
gpg --export --armor <user-id> > public.key
|
||||
```
|
||||
|
||||
### Export key 1:
|
||||
|
||||
```console
|
||||
$ gpg --armor --output public.key --export <user-id>
|
||||
gpg --armor --output public.key --export <user-id>
|
||||
```
|
||||
|
||||
### Export key to server
|
||||
|
||||
```console
|
||||
$ gpg --keyserver pgp.mit.edu --send-keys <user-id>
|
||||
gpg --keyserver pgp.mit.edu --send-keys <user-id>
|
||||
```
|
||||
|
||||
## Cifrado
|
||||
@ -98,32 +98,32 @@ $ gpg --keyserver pgp.mit.edu --send-keys <user-id>
|
||||
#### Cifrar
|
||||
|
||||
```console
|
||||
$ gpg --symmetric <miarchivo>
|
||||
gpg --symmetric <miarchivo>
|
||||
```
|
||||
|
||||
#### Descifrado
|
||||
|
||||
```console
|
||||
$ gpg --output <archivo.ext> --decrypt <archivo.gpg>
|
||||
gpg --output <archivo.ext> --decrypt <archivo.gpg>
|
||||
```
|
||||
|
||||
### Cifrado Asimétrico
|
||||
#### Encryt
|
||||
|
||||
```console
|
||||
$ gpg --recipient <user-id> --encrypt archivo.ext
|
||||
gpg --recipient <user-id> --encrypt archivo.ext
|
||||
```
|
||||
|
||||
#### Decrypt
|
||||
|
||||
```console
|
||||
$ gpg --output archivo.ext --decrypt archivo.ext.gpg
|
||||
gpg --output archivo.ext --decrypt archivo.ext.gpg
|
||||
```
|
||||
|
||||
## Refresh keys
|
||||
|
||||
```console
|
||||
$ gpg --refresh-keys
|
||||
gpg --refresh-keys
|
||||
```
|
||||
|
||||
### wiki
|
||||
|
Loading…
x
Reference in New Issue
Block a user