From 4dea1f032d70830010160d7ceca012c792648d0a Mon Sep 17 00:00:00 2001 From: Jameson Graef Rollins Date: Fri, 5 Sep 2008 22:23:30 -0700 Subject: [PATCH] dkg gets all of the credit for us finally being able to put to death seckey2sshagent. If we need it, we know where it is. rip. --- src/seckey2sshagent | 143 -------------------------------------------- 1 file changed, 143 deletions(-) delete mode 100755 src/seckey2sshagent diff --git a/src/seckey2sshagent b/src/seckey2sshagent deleted file mode 100755 index a516256..0000000 --- a/src/seckey2sshagent +++ /dev/null @@ -1,143 +0,0 @@ -#!/bin/bash - -# seckey2sshagent: this is a hack of a script to cope with the fact -# that openpgp2ssh currently cannot support encrypted secret keys. - -# the basic operating principal is: - -# export the secret key in encrypted format to a new keyring - -# remove the passphrase in that keyring - -# use that keyring with openpgp2ssh - -# Authors: Daniel Kahn Gillmor , -# Jameson Rollins - -explanation() { - - cat < - -followed by the empty string for the new password. GPG will ask you -if you're really sure. Answer yes, because this is only relevant to -the temporary keyring. Then, do: - - save - -At this point, your key will be added to your running ssh-agent with -the alias 'monkeysphere-key' and seckey2sshagent should terminate. -You can check on it with: - - ssh-add -l - -EOF -} - -cleanup() { - echo -n "removing temp gpg home... " 1>&2 - rm -rf "$TMPPRIVATE" - echo "done." 1>&2 -} - -export_sec_key() { - gpg --export-secret-key "$GPGID" | GNUPGHOME="$TMPPRIVATE" gpg --import - - GNUPGHOME="$TMPPRIVATE" gpg --edit-key "$GPGID" - - # idea to script the password stuff. not working. - # read -s -p "enter gpg password: " PASSWD; echo - # cmd=$(cat < "$TMPPRIVATE/key" - # passprotect file - ssh-keygen -f "${TMPPRIVATE}/key" -p - # move into place - mv "${TMPPRIVATE}/key" "$FILE" - - # export public key - gpg --export "$GPGID" | openpgp2ssh "$GPGID" > "${FILE}.pub" - - # otherwise add to agent - else - KEYNAME='MonkeySphere Key '$(echo "$GPGID" | tr -c -d '0-9a-fA-F')'' - - # creating this alias so the key is named "monkeysphere-key" in the - # comment stored by the agent, while never being written to disk in - # SSH form: - ln -s /dev/stdin "${TMPPRIVATE}/${KEYNAME}" - - # export secret key to agent - export_sec_key | (cd "$TMPPRIVATE" && ssh-add -c "$KEYNAME") - fi - -done -- 2.25.1