diff options
| author | Miles Bader | 2005-06-30 00:27:41 +0000 |
|---|---|---|
| committer | Miles Bader | 2005-06-30 00:27:41 +0000 |
| commit | 84861437f914ac45c1eea7b6477ffc4783bb3bdd (patch) | |
| tree | b4656cb1585c585d93178d9dac777a015652e118 /lisp | |
| parent | 0684376b791ef5fc652893d45c4866eac89268ec (diff) | |
| download | emacs-84861437f914ac45c1eea7b6477ffc4783bb3bdd.tar.gz emacs-84861437f914ac45c1eea7b6477ffc4783bb3bdd.zip | |
Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-458
Merge from gnus--rel--5.10
Patches applied:
* gnus--rel--5.10 (patch 83-85)
- Merge from emacs--cvs-trunk--0
- Update from CVS
2005-06-29 Katsumi Yamaoka <yamaoka@jpl.org>
* lisp/gnus/gnus-nocem.el (gnus-nocem-verifyer): Default to pgg-verify.
(gnus-nocem-check-article): Fetch the Type header.
(gnus-nocem-message-wanted-p): Fix the way to examine types.
(gnus-nocem-verify-issuer): Use functionp instead of fboundp.
(gnus-nocem-enter-article): Make sure gnus-nocem-hashtb is initialized.
* lisp/gnus/pgg.el (pgg-verify): Return the verification result.
2005-06-29 Katsumi Yamaoka <yamaoka@jpl.org>
* man/gnus.texi (NoCeM): gnus-nocem-verifyer defaults to pgg-verify.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/gnus/ChangeLog | 10 | ||||
| -rw-r--r-- | lisp/gnus/gnus-nocem.el | 24 | ||||
| -rw-r--r-- | lisp/gnus/pgg.el | 3 |
3 files changed, 27 insertions, 10 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index b7698350efb..1f305f3adeb 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,13 @@ | |||
| 1 | 2005-06-29 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 2 | |||
| 3 | * gnus-nocem.el (gnus-nocem-verifyer): Default to pgg-verify. | ||
| 4 | (gnus-nocem-check-article): Fetch the Type header. | ||
| 5 | (gnus-nocem-message-wanted-p): Fix the way to examine types. | ||
| 6 | (gnus-nocem-verify-issuer): Use functionp instead of fboundp. | ||
| 7 | (gnus-nocem-enter-article): Make sure gnus-nocem-hashtb is initialized. | ||
| 8 | |||
| 9 | * pgg.el (pgg-verify): Return the verification result. | ||
| 10 | |||
| 1 | 2005-06-24 Juanma Barranquero <lekktu@gmail.com> | 11 | 2005-06-24 Juanma Barranquero <lekktu@gmail.com> |
| 2 | 12 | ||
| 3 | * gnus-art.el (gnus-article-mode): Set `nobreak-char-display', not | 13 | * gnus-art.el (gnus-article-mode): Set `nobreak-char-display', not |
diff --git a/lisp/gnus/gnus-nocem.el b/lisp/gnus/gnus-nocem.el index 5a5f779b732..cd51efcf100 100644 --- a/lisp/gnus/gnus-nocem.el +++ b/lisp/gnus/gnus-nocem.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; gnus-nocem.el --- NoCeM pseudo-cancellation treatment | 1 | ;;; gnus-nocem.el --- NoCeM pseudo-cancellation treatment |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2004 | 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2004, 2005 |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | 6 | ||
| @@ -74,12 +74,13 @@ issuer registry." | |||
| 74 | :group 'gnus-nocem | 74 | :group 'gnus-nocem |
| 75 | :type 'integer) | 75 | :type 'integer) |
| 76 | 76 | ||
| 77 | (defcustom gnus-nocem-verifyer 'mc-verify | 77 | (defcustom gnus-nocem-verifyer 'pgg-verify |
| 78 | "*Function called to verify that the NoCeM message is valid. | 78 | "*Function called to verify that the NoCeM message is valid. |
| 79 | One likely value is `mc-verify'. If the function in this variable | 79 | One likely value is `pgg-verify'. If the function in this variable |
| 80 | isn't bound, the message will be used unconditionally." | 80 | isn't bound, the message will be used unconditionally." |
| 81 | :group 'gnus-nocem | 81 | :group 'gnus-nocem |
| 82 | :type '(radio (function-item mc-verify) | 82 | :type '(radio (function-item pgg-verify) |
| 83 | (function-item mc-verify) | ||
| 83 | (function :tag "other"))) | 84 | (function :tag "other"))) |
| 84 | 85 | ||
| 85 | (defcustom gnus-nocem-liberal-fetch nil | 86 | (defcustom gnus-nocem-liberal-fetch nil |
| @@ -246,7 +247,7 @@ valid issuer, which is much faster if you are selective about the issuers." | |||
| 246 | ;; We get the name of the issuer. | 247 | ;; We get the name of the issuer. |
| 247 | (narrow-to-region b e) | 248 | (narrow-to-region b e) |
| 248 | (setq issuer (mail-fetch-field "issuer") | 249 | (setq issuer (mail-fetch-field "issuer") |
| 249 | type (mail-fetch-field "issuer")) | 250 | type (mail-fetch-field "type")) |
| 250 | (widen) | 251 | (widen) |
| 251 | (if (not (gnus-nocem-message-wanted-p issuer type)) | 252 | (if (not (gnus-nocem-message-wanted-p issuer type)) |
| 252 | (message "invalid NoCeM issuer: %s" issuer) | 253 | (message "invalid NoCeM issuer: %s" issuer) |
| @@ -267,18 +268,20 @@ valid issuer, which is much faster if you are selective about the issuers." | |||
| 267 | (while (setq condition (pop conditions)) | 268 | (while (setq condition (pop conditions)) |
| 268 | (cond | 269 | (cond |
| 269 | ((stringp condition) | 270 | ((stringp condition) |
| 270 | (setq wanted (string-match condition type))) | 271 | (when (string-match condition type) |
| 272 | (setq wanted t))) | ||
| 271 | ((and (consp condition) | 273 | ((and (consp condition) |
| 272 | (eq (car condition) 'not) | 274 | (eq (car condition) 'not) |
| 273 | (stringp (cadr condition))) | 275 | (stringp (cadr condition))) |
| 274 | (setq wanted (not (string-match (cadr condition) type)))) | 276 | (when (string-match (cadr condition) type) |
| 277 | (setq wanted nil))) | ||
| 275 | (t | 278 | (t |
| 276 | (error "Invalid NoCeM condition: %S" condition)))) | 279 | (error "Invalid NoCeM condition: %S" condition)))) |
| 277 | wanted)))) | 280 | wanted)))) |
| 278 | 281 | ||
| 279 | (defun gnus-nocem-verify-issuer (person) | 282 | (defun gnus-nocem-verify-issuer (person) |
| 280 | "Verify using PGP that the canceler is who she says she is." | 283 | "Verify using PGP that the canceler is who she says she is." |
| 281 | (if (fboundp gnus-nocem-verifyer) | 284 | (if (functionp gnus-nocem-verifyer) |
| 282 | (ignore-errors | 285 | (ignore-errors |
| 283 | (funcall gnus-nocem-verifyer)) | 286 | (funcall gnus-nocem-verifyer)) |
| 284 | ;; If we don't have Mailcrypt, then we use the message anyway. | 287 | ;; If we don't have Mailcrypt, then we use the message anyway. |
| @@ -315,7 +318,10 @@ valid issuer, which is much faster if you are selective about the issuers." | |||
| 315 | (while (eq (char-after) ?\t) | 318 | (while (eq (char-after) ?\t) |
| 316 | (forward-line -1)) | 319 | (forward-line -1)) |
| 317 | (setq id (buffer-substring (point) (1- (search-forward "\t")))) | 320 | (setq id (buffer-substring (point) (1- (search-forward "\t")))) |
| 318 | (unless (gnus-gethash id gnus-nocem-hashtb) | 321 | (unless (if gnus-nocem-hashtb |
| 322 | (gnus-gethash id gnus-nocem-hashtb) | ||
| 323 | (setq gnus-nocem-hashtb (gnus-make-hashtable)) | ||
| 324 | nil) | ||
| 319 | ;; only store if not already present | 325 | ;; only store if not already present |
| 320 | (gnus-sethash id t gnus-nocem-hashtb) | 326 | (gnus-sethash id t gnus-nocem-hashtb) |
| 321 | (push id ncm)) | 327 | (push id ncm)) |
diff --git a/lisp/gnus/pgg.el b/lisp/gnus/pgg.el index eff02a1c32a..ca351c90cd2 100644 --- a/lisp/gnus/pgg.el +++ b/lisp/gnus/pgg.el | |||
| @@ -380,7 +380,8 @@ within the region." | |||
| 380 | (with-output-to-temp-buffer pgg-echo-buffer | 380 | (with-output-to-temp-buffer pgg-echo-buffer |
| 381 | (set-buffer standard-output) | 381 | (set-buffer standard-output) |
| 382 | (insert-buffer-substring (if status pgg-output-buffer | 382 | (insert-buffer-substring (if status pgg-output-buffer |
| 383 | pgg-errors-buffer))))))) | 383 | pgg-errors-buffer))))) |
| 384 | status)) | ||
| 384 | 385 | ||
| 385 | ;;;###autoload | 386 | ;;;###autoload |
| 386 | (defun pgg-insert-key () | 387 | (defun pgg-insert-key () |