X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=lisp%2Fsieve-manage.el;h=6f91f5bbff67c2d015d38a82ac0c7e5cdd9cefb6;hb=9b741e050b400987d68ff761c6cc3276c932839c;hp=b87d7cd3f72778711025b0ae4ea2db878862bdcb;hpb=ccafddd52118358ade01985eba8b7f7fe52b95de;p=elisp%2Fgnus.git- diff --git a/lisp/sieve-manage.el b/lisp/sieve-manage.el index b87d7cd..6f91f5b 100644 --- a/lisp/sieve-manage.el +++ b/lisp/sieve-manage.el @@ -64,8 +64,6 @@ ;; Release history: ;; ;; 2001-10-31 Committed to Oort Gnus. -;; -;; $Id: sieve-manage.el,v 1.1.2.1 2001-11-01 08:25:40 yamaoka Exp $ ;;; Code: @@ -107,7 +105,7 @@ (starttls sieve-manage-starttls-p sieve-manage-starttls-open)) "Definition of network streams. -(NAME CHECK OPEN) +\(NAME CHECK OPEN) NAME names the stream, CHECK is a function returning non-nil if the server support the stream and OPEN is a function for opening the @@ -116,16 +114,16 @@ stream.") (defcustom sieve-manage-authenticators '(cram-md5 plain) "Priority of authenticators to consider when authenticating to server.") -(defcustom sieve-manage-authenticator-alist +(defcustom sieve-manage-authenticator-alist '((cram-md5 sieve-manage-cram-md5-p sieve-manage-cram-md5-auth) (plain sieve-manage-plain-p sieve-manage-plain-auth)) "Definition of authenticators. -(NAME CHECK AUTHENTICATE) +\(NAME CHECK AUTHENTICATE) NAME names the authenticator. CHECK is a function returning non-nil if the server support the authenticator and AUTHENTICATE is a function -for doing the actuall authentification.") +for doing the actual authentication.") (defcustom sieve-manage-default-port 2000 "Default port number for managesieve protocol." @@ -196,13 +194,13 @@ Returns t if login was successful, nil otherwise." ;; (condition-case () (while (or (not user) (not passwd)) (setq user (or sieve-manage-username - (read-from-minibuffer + (read-from-minibuffer (concat "Managesieve username for " sieve-manage-server ": ") (or user sieve-manage-default-user)))) (setq passwd (or sieve-manage-password (sieve-manage-read-passwd - (concat "Managesieve password for " user "@" + (concat "Managesieve password for " user "@" sieve-manage-server ": ")))) (when (and user passwd) (if (funcall loginfunc user passwd) @@ -319,7 +317,7 @@ Returns t if login was successful, nil otherwise." (sieve-manage-send (concat "AUTHENTICATE \"PLAIN\" \"" (base64-encode-string (concat (char-to-string 0) - user + user (char-to-string 0) passwd)) "\"")) @@ -341,7 +339,7 @@ Returns t if login was successful, nil otherwise." (let* ((done (sieve-manage-interactive-login buffer (lambda (user passwd) - (sieve-manage-send "AUTHENTICATE \"CRAM-MD5\" \"\"") + (sieve-manage-send "AUTHENTICATE \"CRAM-MD5\"") (sieve-manage-send (concat "\"" @@ -395,7 +393,7 @@ to work in." (if (funcall (nth 1 (assq stream sieve-manage-stream-alist)) buffer) (setq stream-changed - (not (eq (or sieve-manage-stream + (not (eq (or sieve-manage-stream sieve-manage-default-stream) stream)) sieve-manage-stream stream @@ -409,14 +407,14 @@ to work in." (if (sieve-manage-open-1 buffer) (message "sieve: Reconnecting with stream `%s'...done" sieve-manage-stream) - (message "sieve: Reconnecting with stream `%s'...failed" + (message "sieve: Reconnecting with stream `%s'...failed" sieve-manage-stream)) (setq sieve-manage-capability nil)) (if (sieve-manage-opened buffer) ;; Choose authenticator (when (and (null sieve-manage-auth) (not (eq sieve-manage-state 'auth))) - (let ((auths sieve-manage-authenticators)) + (let ((auths sieve-manage-authenticators)) (while (setq auth (pop auths)) (if (funcall (nth 1 (assq auth