From a9c98d1b5aeeb96fc05a64eb645653b5c417c3d2 Mon Sep 17 00:00:00 2001 From: yamaoka Date: Thu, 10 Oct 2002 00:40:50 +0000 Subject: [PATCH] Synch with Oort Gnus. --- lisp/ChangeLog | 14 ++++++++++++++ lisp/mml.el | 24 ++++++++++++++++++++++-- 2 files changed, 36 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e0e149e..1204c4c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,19 @@ 2002-10-10 Simon Josefsson + * pgg.el (pgg-decrypt-region): Bind pgg-default-user-id to + key-identifier in packet. Is this a good idea? + + * mml.el (mml-mode-map): Add security commands that operates on + MIME parts. + (mml-menu): And menu items for them. + + * mml1991.el (mml1991-pgg-encrypt): Remove headers. + + * mml.el (mml-parse-1): Support sender in #secure tags. + + * mml1991.el (mml1991-pgg-sign): Only use message-sender if it is + defined. + * mml-sec.el (mml-smime-encrypt-buffer): Warn about combined signing. (mml-pgp-encrypt-buffer): Support combined signing. diff --git a/lisp/mml.el b/lisp/mml.el index d97ec34..922a7fa 100644 --- a/lisp/mml.el +++ b/lisp/mml.el @@ -151,6 +151,7 @@ one charsets.") (let* (secure-mode (taginfo (mml-read-tag)) (recipients (cdr (assq 'recipients taginfo))) + (sender (cdr (assq 'sender taginfo))) (location (cdr (assq 'tag-location taginfo))) (mode (cdr (assq 'mode taginfo))) (method (cdr (assq 'method taginfo))) @@ -174,7 +175,9 @@ one charsets.") (eval `(mml-insert-tag ,secure-mode ,@tags ,(if recipients "recipients") - ,recipients)) + ,recipients + ,(if sender "sender") + ,sender)) ;; restart the parse (goto-char location))) ((looking-at "<#multipart") @@ -790,14 +793,22 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (defvar mml-mode-map (let ((sign (make-sparse-keymap)) (encrypt (make-sparse-keymap)) + (signpart (make-sparse-keymap)) + (encryptpart (make-sparse-keymap)) (map (make-sparse-keymap)) (main (make-sparse-keymap))) (define-key sign "p" 'mml-secure-message-sign-pgpmime) (define-key sign "o" 'mml-secure-message-sign-pgp) (define-key sign "s" 'mml-secure-message-sign-smime) + (define-key signpart "p" 'mml-secure-sign-pgpmime) + (define-key signpart "o" 'mml-secure-sign-pgp) + (define-key signpart "s" 'mml-secure-sign-smime) (define-key encrypt "p" 'mml-secure-message-encrypt-pgpmime) (define-key encrypt "o" 'mml-secure-message-encrypt-pgp) (define-key encrypt "s" 'mml-secure-message-encrypt-smime) + (define-key encryptpart "p" 'mml-secure-encrypt-pgpmime) + (define-key encryptpart "o" 'mml-secure-encrypt-pgp) + (define-key encryptpart "s" 'mml-secure-encrypt-smime) (define-key map "\C-n" 'mml-unsecure-message) (define-key map "f" 'mml-attach-file) (define-key map "b" 'mml-attach-buffer) @@ -808,7 +819,9 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (define-key map "v" 'mml-validate) (define-key map "P" 'mml-preview) (define-key map "s" sign) - (define-key map "c" encrypt) + (define-key map "S" sign) + (define-key map "c" encryptpart) + (define-key map "C" encryptpart) ;;(define-key map "n" 'mml-narrow-to-part) ;; `M-m' conflicts with `back-to-indentation'. ;; (define-key main "\M-m" map) @@ -831,6 +844,13 @@ If HANDLES is non-nil, use it instead reparsing the buffer." ["PGP Encrypt" mml-secure-message-encrypt-pgp t] ["S/MIME Sign" mml-secure-message-sign-smime t] ["S/MIME Encrypt" mml-secure-message-encrypt-smime t] + ("Secure MIME part" + ["PGP/MIME Sign Part" mml-secure-sign-pgpmime t] + ["PGP/MIME Encrypt Part" mml-secure-encrypt-pgpmime t] + ["PGP Sign Part" mml-secure-sign-pgp t] + ["PGP Encrypt Part" mml-secure-encrypt-pgp t] + ["S/MIME Sign Part" mml-secure-sign-smime t] + ["S/MIME Encrypt Part" mml-secure-encrypt-smime t]) ["Encrypt/Sign off" mml-unsecure-message t] ;;["Narrow" mml-narrow-to-part t] ["Quote MML" mml-quote-region t] -- 1.7.10.4