From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/77566 Path: news.gmane.org!not-for-mail From: Michael Welsh Duggan Newsgroups: gmane.emacs.gnus.general Subject: sieve-manage no longer works without authinfo Date: Mon, 07 Mar 2011 01:04:25 -0500 Message-ID: <878vwr5uvq.fsf@maru.md5i.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1299477952 31751 80.91.229.12 (7 Mar 2011 06:05:52 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 7 Mar 2011 06:05:52 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M25889@lists.math.uh.edu Mon Mar 07 07:05:48 2011 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PwTZj-0002GC-1C for ding-account@gmane.org; Mon, 07 Mar 2011 07:05:47 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1PwTYd-0000aq-Ho; Mon, 07 Mar 2011 00:04:39 -0600 Original-Received: from mx1.math.uh.edu ([129.7.128.32]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1PwTYa-0000aR-Eu for ding@lists.math.uh.edu; Mon, 07 Mar 2011 00:04:36 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx1.math.uh.edu with esmtp (Exim 4.72) (envelope-from ) id 1PwTYY-0000iG-HW for ding@lists.math.uh.edu; Mon, 07 Mar 2011 00:04:36 -0600 Original-Received: from md5i.com ([75.151.244.229] helo=maru.md5i.com) by quimby.gnus.org with esmtp (Exim 4.72) (envelope-from ) id 1PwTYW-0004lo-P8 for ding@gnus.org; Mon, 07 Mar 2011 07:04:33 +0100 Original-Received: from md5i by maru.md5i.com with local (Exim 4.74) (envelope-from ) id 1PwTYP-0003JZ-TE for ding@gnus.org; Mon, 07 Mar 2011 01:04:25 -0500 User-Agent: Gnus/5.110014 (No Gnus v0.14) Emacs/24.0.50 (gnu/linux) X-Spam-Score: -1.9 (-) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:77566 Archived-At: If an entry does not exists for a server in .authinfo, `sieve-manage' is failing like this: Debugger entered--Lisp error: (wrong-type-argument arrayp nil) fillarray(nil 0) sasl-digest-md5-response-value(nil "maru" "Kl93DxIqWEE4iqoNYz5qdoljslNK1/= qkjIvYk8HQ/c4=3D" "4o7fa2m639mza2m6" 1 "auth" "sieve/localhost" nil) sasl-digest-md5-response([["DIGEST-MD5" (ignore sasl-digest-md5-response = ignore)] nil "sieve" "localhost" sasl-client-properties] [ignore "nonce=3D\= "Kl93DxIqWEE4iqoNYz5qdoljslNK1/qkjIvYk8HQ/c4=3D\",realm=3D\"maru\",qop=3D\"= auth,auth-int,auth-conf\",cipher=3D\"rc4-40,rc4-56,rc4,des,3des\",maxbuf=3D= 4096,charset=3Dutf-8,algorithm=3Dmd5-sess"]) sasl-next-step([["DIGEST-MD5" (ignore sasl-digest-md5-response ignore)] n= il "sieve" "localhost" sasl-client-properties] [ignore "nonce=3D\"Kl93DxIqW= EE4iqoNYz5qdoljslNK1/qkjIvYk8HQ/c4=3D\",realm=3D\"maru\",qop=3D\"auth,auth-= int,auth-conf\",cipher=3D\"rc4-40,rc4-56,rc4,des,3des\",maxbuf=3D4096,chars= et=3Dutf-8,algorithm=3Dmd5-sess"]) (setq step (sasl-next-step client step)) (while t (setq rsp nil) (goto-char (point-min)) (while (null (or (progn (= setq rsp (sieve-manage-is-string)) (if (not (and rsp ...)) (setq rsp nil) (= goto-char (match-end 0)) rsp)) (setq rsp (sieve-manage-is-okno)))) (accept-= process-output sieve-manage-process 1) (goto-char (point-min))) (sieve-mana= ge-erase) (when (sieve-manage-ok-p rsp) (when (and (cadr rsp) (string-match= "^SASL \"\\([^\"]+\\)\"" (cadr rsp))) (sasl-step-set-data step (base64-dec= ode-string (match-string 1 (cadr rsp))))) (if (and (setq step (sasl-next-st= ep client step)) (setq data (sasl-step-data step))) (error "Server not read= y for SASL data: %s" data) (throw (quote done) t))) (unless (stringp rsp) (= error "Server aborted SASL authentication: %s" (caddr rsp))) (sasl-step-set= -data step (base64-decode-string rsp)) (setq step (sasl-next-step client st= ep)) (sieve-manage-send (if (sasl-step-data step) (concat "\"" (base64-enco= de-string (sasl-step-data step) (quote no-line-break)) "\"") ""))) (catch (quote done) (while t (setq rsp nil) (goto-char (point-min)) (whil= e (null (or (progn (setq rsp (sieve-manage-is-string)) (if (not ...) (setq = rsp nil) (goto-char ...) rsp)) (setq rsp (sieve-manage-is-okno)))) (accept-= process-output sieve-manage-process 1) (goto-char (point-min))) (sieve-mana= ge-erase) (when (sieve-manage-ok-p rsp) (when (and (cadr rsp) (string-match= "^SASL \"\\([^\"]+\\)\"" (cadr rsp))) (sasl-step-set-data step (base64-dec= ode-string (match-string 1 (cadr rsp))))) (if (and (setq step (sasl-next-st= ep client step)) (setq data (sasl-step-data step))) (error "Server not read= y for SASL data: %s" data) (throw (quote done) t))) (unless (stringp rsp) (= error "Server aborted SASL authentication: %s" (caddr rsp))) (sasl-step-set= -data step (base64-decode-string rsp)) (setq step (sasl-next-step client st= ep)) (sieve-manage-send (if (sasl-step-data step) (concat "\"" (base64-enco= de-string (sasl-step-data step) (quote no-line-break)) "\"") "")))) (let* ((auth-info (auth-source-search :host sieve-manage-server :port "si= eve" :max 1)) (user-name (plist-get (nth 0 auth-info) :user)) (user-passwor= d (plist-get (nth 0 auth-info) :secret)) (user-password (if (functionp user= -password) (funcall user-password) user-password)) (client (sasl-make-clien= t (sasl-find-mechanism (list mech)) user-name "sieve" sieve-manage-server))= (sasl-read-passphrase (\` (lambda (prompt) (\, (copy-sequence user-passwor= d))))) (step (sasl-next-step client nil)) (tag (sieve-manage-send (concat "= AUTHENTICATE \"" mech "\"" (and (sasl-step-data step) (concat " \"" (base64= -encode-string ... ...) "\""))))) data rsp) (catch (quote done) (while t (s= etq rsp nil) (goto-char (point-min)) (while (null (or (progn (setq rsp ...)= (if ... ... ... rsp)) (setq rsp (sieve-manage-is-okno)))) (accept-process-= output sieve-manage-process 1) (goto-char (point-min))) (sieve-manage-erase= ) (when (sieve-manage-ok-p rsp) (when (and (cadr rsp) (string-match "^SASL = \"\\([^\"]+\\)\"" (cadr rsp))) (sasl-step-set-data step (base64-decode-stri= ng (match-string 1 ...)))) (if (and (setq step (sasl-next-step client step)= ) (setq data (sasl-step-data step))) (error "Server not ready for SASL data= : %s" data) (throw (quote done) t))) (unless (stringp rsp) (error "Server a= borted SASL authentication: %s" (caddr rsp))) (sasl-step-set-data step (bas= e64-decode-string rsp)) (setq step (sasl-next-step client step)) (sieve-man= age-send (if (sasl-step-data step) (concat "\"" (base64-encode-string (sasl= -step-data step) (quote no-line-break)) "\"") "")))) (message "sieve: Login= using %s...done" mech)) (save-current-buffer (set-buffer buffer) (let* ((auth-info (auth-source-s= earch :host sieve-manage-server :port "sieve" :max 1)) (user-name (plist-ge= t (nth 0 auth-info) :user)) (user-password (plist-get (nth 0 auth-info) :se= cret)) (user-password (if (functionp user-password) (funcall user-password)= user-password)) (client (sasl-make-client (sasl-find-mechanism (list mech)= ) user-name "sieve" sieve-manage-server)) (sasl-read-passphrase (\` (lambda= (prompt) (\, (copy-sequence user-password))))) (step (sasl-next-step clien= t nil)) (tag (sieve-manage-send (concat "AUTHENTICATE \"" mech "\"" (and (s= asl-step-data step) (concat " \"" ... "\""))))) data rsp) (catch (quote don= e) (while t (setq rsp nil) (goto-char (point-min)) (while (null (or (progn = ... ...) (setq rsp ...))) (accept-process-output sieve-manage-process 1) (g= oto-char (point-min))) (sieve-manage-erase) (when (sieve-manage-ok-p rsp) (= when (and (cadr rsp) (string-match "^SASL \"\\([^\"]+\\)\"" ...)) (sasl-ste= p-set-data step (base64-decode-string ...))) (if (and (setq step ...) (setq= data ...)) (error "Server not ready for SASL data: %s" data) (throw (quote= done) t))) (unless (stringp rsp) (error "Server aborted SASL authenticatio= n: %s" (caddr rsp))) (sasl-step-set-data step (base64-decode-string rsp)) (= setq step (sasl-next-step client step)) (sieve-manage-send (if (sasl-step-d= ata step) (concat "\"" (base64-encode-string ... ...) "\"") "")))) (message= "sieve: Login using %s...done" mech))) (with-current-buffer buffer (let* ((auth-info (auth-source-search :host s= ieve-manage-server :port "sieve" :max 1)) (user-name (plist-get (nth 0 auth= -info) :user)) (user-password (plist-get (nth 0 auth-info) :secret)) (user-= password (if (functionp user-password) (funcall user-password) user-passwor= d)) (client (sasl-make-client (sasl-find-mechanism (list mech)) user-name "= sieve" sieve-manage-server)) (sasl-read-passphrase (\` (lambda (prompt) (\,= (copy-sequence user-password))))) (step (sasl-next-step client nil)) (tag = (sieve-manage-send (concat "AUTHENTICATE \"" mech "\"" (and (sasl-step-data= step) (concat " \"" ... "\""))))) data rsp) (catch (quote done) (while t (= setq rsp nil) (goto-char (point-min)) (while (null (or (progn ... ...) (set= q rsp ...))) (accept-process-output sieve-manage-process 1) (goto-char (poi= nt-min))) (sieve-manage-erase) (when (sieve-manage-ok-p rsp) (when (and (ca= dr rsp) (string-match "^SASL \"\\([^\"]+\\)\"" ...)) (sasl-step-set-data st= ep (base64-decode-string ...))) (if (and (setq step ...) (setq data ...)) (= error "Server not ready for SASL data: %s" data) (throw (quote done) t))) (= unless (stringp rsp) (error "Server aborted SASL authentication: %s" (caddr= rsp))) (sasl-step-set-data step (base64-decode-string rsp)) (setq step (sa= sl-next-step client step)) (sieve-manage-send (if (sasl-step-data step) (co= ncat "\"" (base64-encode-string ... ...) "\"") "")))) (message "sieve: Logi= n using %s...done" mech))) sieve-sasl-auth(# "DIGEST-MD5") sieve-manage-digest-md5-auth(#) funcall(sieve-manage-digest-md5-auth #) (if (funcall (nth 2 (assq sieve-manage-auth sieve-manage-authenticator-al= ist)) (current-buffer)) (progn (setq sieve-manage-state (quote auth)))) (when (funcall (nth 2 (assq sieve-manage-auth sieve-manage-authenticator-= alist)) (current-buffer)) (setq sieve-manage-state (quote auth))) (if (eq sieve-manage-state (quote nonauth)) (when (funcall (nth 2 (assq s= ieve-manage-auth sieve-manage-authenticator-alist)) (current-buffer)) (setq= sieve-manage-state (quote auth))) sieve-manage-state) (save-current-buffer (set-buffer (or buffer (current-buffer))) (if (eq si= eve-manage-state (quote nonauth)) (when (funcall (nth 2 (assq sieve-manage-= auth sieve-manage-authenticator-alist)) (current-buffer)) (setq sieve-manag= e-state (quote auth))) sieve-manage-state)) (with-current-buffer (or buffer (current-buffer)) (if (eq sieve-manage-st= ate (quote nonauth)) (when (funcall (nth 2 (assq sieve-manage-auth sieve-ma= nage-authenticator-alist)) (current-buffer)) (setq sieve-manage-state (quot= e auth))) sieve-manage-state)) sieve-manage-authenticate() sieve-open-server("localhost" nil) sieve-manage("localhost") call-interactively(sieve-manage t nil) execute-extended-command(nil) call-interactively(execute-extended-command nil nil) --=20 Michael Welsh Duggan (md5i@md5i.com)