From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/77341 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.gnus.general Subject: Re: Making Gnus ask my IMAP username and password after the recent auth-source changes Date: Fri, 25 Feb 2011 05:31:38 -0600 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <87d3mg4ag5.fsf@lifelogs.com> References: <87sjvq127b.fsf@gmail.com> <878vxhmmvj.fsf@lifelogs.com> <87tyg53tju.fsf@gmail.com> <87ipwj4wu8.fsf@lifelogs.com> <87hbc39vwe.fsf@gmail.com> <87d3mqj36i.fsf@lifelogs.com> <87aahu3fwp.fsf@lifelogs.com> <87pqqq8bfk.fsf@gnus.org> <87zkptw0ws.fsf@lifelogs.com> <87fwrl0wj6.fsf@gnus.org> <87hbbvybwp.fsf@lifelogs.com> <87d3mj3zfs.fsf@gnus.org> <871v2yq040.fsf@lifelogs.com> <87r5ayllt3.fsf@lifelogs.com> <87ipwalgun.fsf@lifelogs.com> <87oc60bu8q.fsf@gnus.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1298633532 9392 80.91.229.12 (25 Feb 2011 11:32:12 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 25 Feb 2011 11:32:12 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M25666@lists.math.uh.edu Fri Feb 25 12:32:08 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 1Psvu3-0007Yh-QK for ding-account@gmane.org; Fri, 25 Feb 2011 12:32:08 +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 1Psvtv-00023w-KG; Fri, 25 Feb 2011 05:31:59 -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 1Psvtt-00023Y-SL for ding@lists.math.uh.edu; Fri, 25 Feb 2011 05:31:57 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx1.math.uh.edu with esmtp (Exim 4.72) (envelope-from ) id 1Psvtp-000422-Dd for ding@lists.math.uh.edu; Fri, 25 Feb 2011 05:31:57 -0600 Original-Received: from lo.gmane.org ([80.91.229.12]) by quimby.gnus.org with esmtp (Exim 4.72) (envelope-from ) id 1Psvto-0003K1-Mk for ding@gnus.org; Fri, 25 Feb 2011 12:31:52 +0100 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Psvto-0007T2-BW for ding@gnus.org; Fri, 25 Feb 2011 12:31:52 +0100 Original-Received: from c-67-186-102-106.hsd1.il.comcast.net ([67.186.102.106]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 25 Feb 2011 12:31:52 +0100 Original-Received: from tzz by c-67-186-102-106.hsd1.il.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 25 Feb 2011 12:31:52 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 41 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: c-67-186-102-106.hsd1.il.comcast.net X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6;d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" User-Agent: Gnus/5.110014 (No Gnus v0.14) Emacs/24.0.50 (gnu/linux) Cancel-Lock: sha1:m12wyDvjyziXkjDZ/XsYkOQ/g5s= X-Spam-Score: -1.9 (-) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:77341 Archived-At: On Thu, 24 Feb 2011 20:42:13 -0800 Lars Ingebrigtsen wrote: LI> Ted Zlatanov writes: >> nnimap.el should handle the case where the returned info doesn't have a >> password. There are cases where IMAP servers do not require a password, >> so it would not be appropriate to ask in `nnimap-credentials'. LI> Hm. Are there any servers that require just a user name and not a LI> password? The problem is that auth-source didn't get a password for whatever reason. netrc lines can have no password, for instance (which is the use case here, in which case the netrc file just has the user, port, and host). The issue is that omitting :secret from the search says "any password will do, including nil". On *creation* the password will be required by the netrc backend, but the search results will be happy without it. We can add a :required list parameter which would filter out results that don't contain those tokens. Then the `auth-source-search' caller would be guaranteed that any results will have the :required tokens. Yeah, that would work. >> (defmacro nnimap-login-password (password) >> (setq password (if password >> password >> (read-passwd "Password: ")))) >> >> This is something that Lars will have to do, though. I don't know that >> code well enough to say whether it's the right solution; the password >> prompt should mention the server, user name, and port. And it may make >> sense to do this prompting for the user name as well. LI> Sorry, I don't understand the use case here. If auth-source didn't LI> return a password, nnimap should then query for a password? Yes. So if we don't add :required to `auth-source-search', nnimap.el will have to do this. Let me know which one you like better. Ted