Skip to content

Commit

Permalink
chore: update docs and fix broken links
Browse files Browse the repository at this point in the history
  • Loading branch information
smlx committed Oct 25, 2021
1 parent 4a8be8f commit 47c8d0e
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 11 deletions.
36 changes: 27 additions & 9 deletions docs/content/en/docs/gpg-walkthrough.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ This example is intended to illustrate how `piv-agent` can integrate with existi

{{% alert title="Note" %}}
This example requires switching between `gpg-agent` and `piv-agent`.
See the [FAQ](/docs/faq) for how to do that.
See the [FAQ](../../docs/faq) for how to do that.
{{% /alert %}}

## Setup
Expand Down Expand Up @@ -397,14 +397,6 @@ The subkey with the most recent date is preferred by `gpg`.

Importantly the master key ID is the same after adding the subkeys, so any existing workflows will continue to work as before.

```
# example ~/.config/git/config
[user]
name = Scott Leggett
email = scott@sl.id.au
signingKey = 9FA216008BDF1AE5E1BCAEC3EC26B2E4240DD2A9
```

### Publish public key

The public key can now be distributed to keyservers and other services such as Github.
Expand Down Expand Up @@ -547,3 +539,29 @@ gpg: AES256 encrypted data
gpg: original file name='foo'
bar
```

### Common software integration

#### git

The same master key ID will work as before, but signing will prefer to use the hardware security device if it is plugged in.

```
# example ~/.config/git/config
[user]
name = Scott Leggett
email = scott@sl.id.au
signingKey = 9FA216008BDF1AE5E1BCAEC3EC26B2E4240DD2A9
[commit]
gpgSign = true
```

#### pass

`pass` has the ability to encrypt to multiple key-ids.
Running `pass init` will re-encrypt existing passwords and configure `pass` to use the specified key-ids for encryption.
As usual, `piv-agent` will use the cryptographic key stored in hardware for decryption if it is available, but fall back to the keyfile otherwise.

```
pass init 0x42B99C3339C9FBC1! 0x84F7BF2FEAC32674!
```
4 changes: 2 additions & 2 deletions docs/content/en/docs/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Private GPG keys to be used by `piv-agent` must be exported to the directory `~/

{{% alert title="Note" %}}
This step requires `gpg-agent` to be running, not `piv-agent`.
See the [FAQ](/docs/faq) for how to switch between the two services.
See the [FAQ](../../docs/faq) for how to switch between the two services.
{{% /alert %}}

{{% alert title="Note" %}}
Expand Down Expand Up @@ -141,4 +141,4 @@ Adding a subkey requires cross-signing between the master key and sub key, so yo

`gpg` will choose the _newest_ available subkey to perform an action. So it will automatically prefer a newly added `piv-agent` subkey over any existing keyfile subkeys, but fall back to keyfiles if e.g. the Yubikey is not plugged in.

See the [GPG Walkthrough](/docs/gpg-walkthrough) for an example of this procedure.
See the [GPG Walkthrough](../../docs/gpg-walkthrough) for an example of this procedure.

0 comments on commit 47c8d0e

Please sign in to comment.