]> gitweb.fluxo.info Git - utils-ssh.git/commitdiff
Placeholder for ssh-agent-loadkey-menu
authorSilvio Rhatto <rhatto@riseup.net>
Tue, 26 Feb 2019 17:09:59 +0000 (14:09 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Tue, 26 Feb 2019 17:09:59 +0000 (14:09 -0300)
ssh-agent-loadkey-menu [new file with mode: 0755]

diff --git a/ssh-agent-loadkey-menu b/ssh-agent-loadkey-menu
new file mode 100755 (executable)
index 0000000..97e20a8
--- /dev/null
@@ -0,0 +1,20 @@
+#!/bin/bash
+#
+# Load a key from a menu.
+#
+
+# Parameters
+BASENAME="`basename $0`"
+KEYS="$HOME/.ssh/keys"
+
+# Check
+if [ ! -d "$KEYS" ]; then
+  echo "$BASENAME: folder not found: $KEYS"
+  exit 1
+fi
+
+# Display menu with available keys
+# Check the selected option
+# Check if the selected option has a custom procedure (monkeysphere, keyringer, etc)
+# Grab passphrase and load the key
+#( cd $KEYS && find -name '*.pub' | grep -v decomissioned )