From: ueno Date: Fri, 26 Nov 1999 06:29:10 +0000 (+0000) Subject: * pgg-gpg.el, pgg-pgp.el, pgg-pgp5.el X-Git-Tag: emiko-1_13_8~15 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=ac3eeba1b7fd1272e98e3965d779fd67d12e6cff;p=elisp%2Fsemi.git * pgg-gpg.el, pgg-pgp.el, pgg-pgp5.el (encrypt-region): Refer `pgg--user-id' if specified. (sign-region): Ditto. (decrypt-region): Ditto. (insert-key): Ditto. --- diff --git a/pgg-gpg.el b/pgg-gpg.el index d6bda0d..e6528b6 100644 --- a/pgg-gpg.el +++ b/pgg-gpg.el @@ -150,7 +150,7 @@ (luna-define-method encrypt-region ((scheme pgg-scheme-gpg) start end recipients) - (let* ((pgg-gpg-user-id pgg-default-user-id) + (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) (args `("--batch" "--armor" "--always-trust" "--encrypt" ,@(if recipients @@ -171,7 +171,7 @@ (luna-define-method decrypt-region ((scheme pgg-scheme-gpg) start end) - (let* ((pgg-gpg-user-id pgg-default-user-id) + (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) (passphrase (pgg-read-passphrase (format "GnuPG passphrase for %s: " pgg-gpg-user-id) @@ -184,7 +184,7 @@ (luna-define-method sign-region ((scheme pgg-scheme-gpg) start end &optional cleartext) - (let* ((pgg-gpg-user-id pgg-default-user-id) + (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) (passphrase (pgg-read-passphrase (format "GnuPG passphrase for %s: " pgg-gpg-user-id) @@ -240,7 +240,7 @@ )) (luna-define-method insert-key ((scheme pgg-scheme-gpg)) - (let* ((pgg-gpg-user-id pgg-default-user-id) + (let* ((pgg-gpg-user-id (or pgg-gpg-user-id pgg-default-user-id)) (args (list "--batch" "--export" "--armor" (concat "\"" pgg-gpg-user-id "\"")))) (pgg-gpg-process-region (point)(point) nil pgg-gpg-program args) diff --git a/pgg-pgp.el b/pgg-pgp.el index 3ba9a96..9193660 100644 --- a/pgg-pgp.el +++ b/pgg-pgp.el @@ -142,7 +142,7 @@ (luna-define-method encrypt-region ((scheme pgg-scheme-pgp) start end recipients) - (let* ((pgg-pgp-user-id pgg-default-user-id) + (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (args `("+encrypttoself=off +verbose=1" "+batchmode" "+language=us" "-fate" @@ -159,7 +159,7 @@ (luna-define-method decrypt-region ((scheme pgg-scheme-pgp) start end) - (let* ((pgg-pgp-user-id pgg-default-user-id) + (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (passphrase (pgg-read-passphrase (format "PGP passphrase for %s: " pgg-pgp-user-id) @@ -174,7 +174,7 @@ (luna-define-method sign-region ((scheme pgg-scheme-pgp) start end &optional clearsign) - (let* ((pgg-pgp-user-id pgg-default-user-id) + (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (passphrase (pgg-read-passphrase (format "PGP passphrase for %s: " pgg-pgp-user-id) @@ -234,7 +234,7 @@ )) (luna-define-method insert-key ((scheme pgg-scheme-pgp)) - (let* ((pgg-pgp-user-id pgg-default-user-id) + (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (args (list "+verbose=1" "+batchmode" "+language=us" "-kxaf" (concat "\"" pgg-pgp-user-id "\"")))) @@ -245,7 +245,7 @@ (luna-define-method snarf-keys-region ((scheme pgg-scheme-pgp) start end) - (let* ((pgg-pgp-user-id pgg-default-user-id) + (let* ((pgg-pgp-user-id (or pgg-pgp-user-id pgg-default-user-id)) (basename (expand-file-name "pgg" temporary-file-directory)) (key-file (make-temp-name basename)) (args diff --git a/pgg-pgp5.el b/pgg-pgp5.el index fc8566e..e8066fb 100644 --- a/pgg-pgp5.el +++ b/pgg-pgp5.el @@ -153,7 +153,7 @@ (luna-define-method encrypt-region ((scheme pgg-scheme-pgp5) start end recipients) - (let* ((pgg-pgp5-user-id pgg-default-user-id) + (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (args `("+NoBatchInvalidKeys=off" "-fat" "+batchmode=1" ,@(if recipients @@ -172,7 +172,7 @@ (luna-define-method decrypt-region ((scheme pgg-scheme-pgp5) start end) - (let* ((pgg-pgp5-user-id pgg-default-user-id) + (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (passphrase (pgg-read-passphrase (format "PGP passphrase for %s: " pgg-pgp5-user-id) @@ -187,7 +187,7 @@ (luna-define-method sign-region ((scheme pgg-scheme-pgp5) start end &optional clearsign) - (let* ((pgg-pgp5-user-id pgg-default-user-id) + (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (passphrase (pgg-read-passphrase (format "PGP passphrase for %s: " pgg-pgp5-user-id) @@ -236,7 +236,7 @@ )) (luna-define-method insert-key ((scheme pgg-scheme-pgp5)) - (let* ((pgg-pgp5-user-id pgg-default-user-id) + (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (args (list "+verbose=1" "+batchmode=1" "+language=us" "-x" (concat "\"" pgg-pgp5-user-id "\"")))) @@ -247,7 +247,7 @@ (luna-define-method snarf-keys-region ((scheme pgg-scheme-pgp5) start end) - (let* ((pgg-pgp5-user-id pgg-default-user-id) + (let* ((pgg-pgp5-user-id (or pgg-pgp5-user-id pgg-default-user-id)) (basename (expand-file-name "pgg" temporary-file-directory)) (key-file (make-temp-name basename)) (args