summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Barrett <tom@tombarrett.xyz>2021-03-11 19:07:58 +0100
committerTom Barrett <tom@tombarrett.xyz>2021-03-11 19:07:58 +0100
commit395c8704da88be4e95df0953938eddf5b0382b3d (patch)
tree9be7c02f0d5595400e0f6dc5bac2c1f0d1b3bb3e
parent040eca1f3e70ba617ae961249928baf85bb634fc (diff)
how to use gpg to manage ssh keys
-rw-r--r--.config/fish/config.fish2
-rw-r--r--.pam_environment2
-rwxr-xr-xbuild5
3 files changed, 9 insertions, 0 deletions
diff --git a/.config/fish/config.fish b/.config/fish/config.fish
index e99e1dc..38413a4 100644
--- a/.config/fish/config.fish
+++ b/.config/fish/config.fish
@@ -14,5 +14,7 @@ function fish_user_key_bindings
end
end
+gpg-connect-agent updatestartuptty /bye > /dev/null
+
function fish_mode_prompt
end
diff --git a/.pam_environment b/.pam_environment
new file mode 100644
index 0000000..b55fba7
--- /dev/null
+++ b/.pam_environment
@@ -0,0 +1,2 @@
+SSH_AGENT_PID DEFAULT=
+SSH_AUTH_SOCK DEFAULT="${XDG_RUNTIME_DIR}/gnupg/S.gpg-agent.ssh"
diff --git a/build b/build
index b6f0ec7..96a3f69 100755
--- a/build
+++ b/build
@@ -71,3 +71,8 @@ ln -s $RC_DIR'/.task' $HOME
# xscreensaver setup
ln -s $RC_DIR'/.xscreensaver' $HOME
+
+# pam setup
+ln -s $RC_DIR'/.pam_environment' $HOME
+
+echo "use gpg --list-secret-keys --with-keygrip, write the [A] keygrip to .gnupg/sshcontrol"