X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;ds=inline;f=src%2Fmonkeysphere-authentication;h=465777d74713aa1202f087df997a57a78d8c443e;hb=c28fa7681093d282acad7f14ecad99b6e209c056;hp=a33de1e56b41e0b3a302a68a0644a81ae8a5ba00;hpb=f54abea9da2be063b0d0ed974f6130b303b2a1c7;p=monkeysphere.git diff --git a/src/monkeysphere-authentication b/src/monkeysphere-authentication index a33de1e..465777d 100755 --- a/src/monkeysphere-authentication +++ b/src/monkeysphere-authentication @@ -31,7 +31,7 @@ MADATADIR="${SYSDATADIR}/authentication" # temp directory to enable atomic moves of authorized_keys files MATMPDIR="${MADATADIR}/tmp" -export MSTMPDIR +export MATMPDIR # UTC date in ISO 8601 format if needed DATE=$(date -u '+%FT%T') @@ -61,12 +61,10 @@ subcommands: remove-id-certifier (c-) KEYID remove a certification key list-id-certifiers (c) list certification keys - expert run expert command - expert help expert command help - version (v) show version number help (h,?) this help +See ${PGRM}(8) for more info. EOF } @@ -88,8 +86,8 @@ gpg_sphere() { su_monkeysphere_user "gpg $@" } -# load the core fingerprint into the fingerprint variable, using the -# gpg host secret key +# output to stdout the core fingerprint from the gpg core secret +# keyring core_fingerprint() { log debug "determining core key fingerprint..." gpg_core --quiet --list-secret-key \ @@ -101,7 +99,7 @@ core_fingerprint() { gpg_core_sphere_sig_transfer() { log debug "exporting core local sigs to sphere..." gpg_core --export-options export-local-sigs --export | \ - gpg_sphere --import-options import-local-sigs --import + gpg_sphere "--import-options import-local-sigs --import" } ######################################################################## @@ -176,35 +174,13 @@ case $COMMAND in list_certifiers "$@" ;; - 'expert') - SUBCOMMAND="$1" - shift - case "$SUBCOMMAND" in - 'help'|'h'|'?') - cat < [options] [args] - -expert subcommands: - diagnostics (d) monkeysphere authentication status - gpg-cmd CMD execute gpg command - -EOF - ;; - - 'diagnostics'|'d') - source "${MASHAREDIR}/diagnostics" - diagnostics - ;; - - 'gpg-cmd') - gpg_sphere "$@" - ;; + 'diagnostics'|'d') + source "${MASHAREDIR}/diagnostics" + diagnostics + ;; - *) - failure "Unknown expert subcommand: '$COMMAND' -Type '$PGRM help' for usage." - ;; - esac + 'gpg-cmd') + gpg_sphere "$@" ;; 'version'|'v')