Merge commit 'jrollins/master'
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Thu, 19 Feb 2009 09:00:48 +0000 (04:00 -0500)
committerDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Thu, 19 Feb 2009 09:00:48 +0000 (04:00 -0500)
src/monkeysphere
src/monkeysphere-host
src/share/m/ssh_proxycommand

index a626a8e41752797deb8542eff73ff5df69019cd3..992ca063ab475f5a554db0c09f787941f8807c34 100755 (executable)
@@ -69,6 +69,10 @@ KNOWN_HOSTS="${HOME}/.ssh/known_hosts"
 HASH_KNOWN_HOSTS="true"
 AUTHORIZED_KEYS="${HOME}/.ssh/authorized_keys"
 
+# unset the check keyserver variable, since that needs to have
+# different defaults for the different functions
+unset CHECK_KEYSERVER
+
 # load global config
 [ -r "${SYSCONFIGDIR}/monkeysphere.conf" ] \
     && . "${SYSCONFIGDIR}/monkeysphere.conf"
@@ -115,7 +119,7 @@ shift
 case $COMMAND in
     'update-known_hosts'|'update-known-hosts'|'k')
        # whether or not to check keyservers
-       CHECK_KEYSERVER=${MONKEYSPHERE_CHECK_KEYSERVER:=$CHECK_KEYSERVER}
+       CHECK_KEYSERVER=${MONKEYSPHERE_CHECK_KEYSERVER:=${CHECK_KEYSERVER:="true"}}
 
        # if hosts are specified on the command line, process just
        # those hosts
@@ -133,7 +137,7 @@ case $COMMAND in
 
     'update-authorized_keys'|'update-authorized-keys'|'a')
        # whether or not to check keyservers
-       CHECK_KEYSERVER=${MONKEYSPHERE_CHECK_KEYSERVER:=$CHECK_KEYSERVER}
+       CHECK_KEYSERVER=${MONKEYSPHERE_CHECK_KEYSERVER:=${CHECK_KEYSERVER:="true"}}
 
        # process authorized_user_ids file
        process_authorized_user_ids "$AUTHORIZED_USER_IDS"
index 9e73ad20debd75f516b0b6d82524a05c6bbb5c4b..00f7c3441a8437bc92704779cafc2d1ede500d69 100755 (executable)
@@ -110,7 +110,7 @@ load_fingerprint() {
            && rm -rf "$FUBAR") <"$HOST_KEY_FILE" \
            | grep '^fpr:' | cut -d: -f10 )
     else
-       HOST_FINGERPRINT=
+       failure "host key gpg pub file not found."
     fi
 }
 
@@ -293,6 +293,7 @@ case $COMMAND in
        ;;
 
     'update-gpg-pub-file')
+       load_fingerprint_secret
        update_gpg_pub_file
        ;;
 
index 29040d856940fe2289b7d6511271f7a77e340706..d7e801ec46711ada104019a5d00628b76b8eb516 100644 (file)
@@ -200,7 +200,6 @@ fi
 CHECK_KEYSERVER=${MONKEYSPHERE_CHECK_KEYSERVER:=$CHECK_KEYSERVER}
 
 # update the known_hosts file for the host
-source "${MSHAREDIR}/update_known_hosts"
 update_known_hosts "$HOSTP"
 
 # output on depending on the return of the update-known_hosts