Subject: password file and two accounts within the same provider

From: "Menge, Oliver" <[email-masked]>
Date: Wed, 12 Feb 2003 12:09:26 +0100 (CET)

Hello together,

is this a bug? I use PINE 4.53 on SUSE Linux. By adding the line

#define PASSFILE ".pine.pwd"

to pine.h I enabled the password saving mechanism which always worked
fine. Now I got a second E-Mail Address from the same provider and I want
to access both inboxes. Here's a snip from my .pinerc

---------<snip>---------------------------------------------------------
incoming-folders=
 om {imap.web.de/ssl/norsh/novalidate-cert/user=Oliver.Menge}inbox,
 joeit {imap.web.de/ssl/norsh/novalidate-cert/user=joe_om},
---------<snip>---------------------------------------------------------

Let's say .pine.pwd exists and is empty and I try to open the 'om'-inbox.
Pine asks for the password and whether to store it on disk. If I agree to
save it and try later to open the 'joeit'-inbox PINE would always open the
om-inbox.

A similar effect I have with the smtp-server authentication, as for the
address [email-masked] I have to use

smtp.web.de/user=Oliver.Menge

and for [email-masked] I have to use

smtp.web.de/user=joe_om.

This I set up with different roles. Again if I save the smtp-password for
user=Oliver.Menge I won't be able to send with [email-masked]. I belive
PINE tries to authentivate with Oliver.Menge, but then the from-line with
[email-masked] is rejected by the smtp-server.

Everything goes oppsite, if (starting from an empty .pine.pwd) I save
first passwords for [email-masked]. Then I'm not able to access my
om-inbox neither can I send E-Mails as [email-masked].

Am I clear? Which further information is needed?

Thanks a lot,

Oliver Menge

-- 
-----------------------------------------------------------------
 For information about this mailing list, and its archives, see: 
 http://www.washington.edu/pine/pine-info/
-----------------------------------------------------------------

---

From: Nancy McGough <[email-masked]>
Date: Wed, 12 Feb 2003 12:19:01 +0000 (GMT)

> save it and try later to open the 'joeit'-inbox PINE would always open the

I also have this problem and I posted about it in this
comp.mail.pine message

 <http://groups.google.com/groups?selm=Pine.OSX.4.53.0301221234060.373%40ybpnyubfg>

It would be great if this were fixed!
Thanks,
Nancy
 coming soon: <http://spam.deflexion.com>

---

From: Steve Hubert <[email-masked]>
Date: Thu, 13 Feb 2003 15:05:37 -0800 (PST)

Yes, it is a bug. If you use pine from sources, here is a patch. It will
be in the next version of pine. Thanks to Oliver and Nancy for the precise
descriptions of the problem.

Steve Hubert

There is a missing left paren in the first different line and a missing
right paren in the second line.

*** imap.c.old	Thu Feb 13 14:58:25 2003
--- imap.c.new	Thu Feb 13 14:59:13 2003
***************
*** 866,891 ****
  	    return;
  	}
  #endif

  	/*
  	 * If no explicit user name supplied and we've not logged in
  	 * with our local user name, see if we've visited this
  	 * host before as someone else.
  	 */
  	if(!*mb->user &&
! 	   (last = imap_get_user(mm_login_list, hostlist))
  #ifdef	PASSFILE
  	   ||
  	   (last = get_passfile_user(ps_global->pinerc, hostlist))
  #endif
! 								  ){
  	    strncpy(user, last, NETMAXUSER);
  	    dprint(9, (debugfile, "mm_login: found user=%s\n", user));

  	    /* try last working password associated with this host/user. */
  	    if(imap_get_passwd(mm_login_list, pwd, user, hostlist,
  	       (mb->sslflag||mb->tlsflag))){
  		dprint(9, (debugfile, "mm_login: found a password for user=%s to try\n", user));
  		return;
  	    }

--- 866,891 ----
  	    return;
  	}
  #endif

  	/*
  	 * If no explicit user name supplied and we've not logged in
  	 * with our local user name, see if we've visited this
  	 * host before as someone else.
  	 */
  	if(!*mb->user &&
! 	  ((last = imap_get_user(mm_login_list, hostlist))
  #ifdef	PASSFILE
  	   ||
  	   (last = get_passfile_user(ps_global->pinerc, hostlist))
  #endif
! 								 )){
  	    strncpy(user, last, NETMAXUSER);
  	    dprint(9, (debugfile, "mm_login: found user=%s\n", user));

  	    /* try last working password associated with this host/user. */
  	    if(imap_get_passwd(mm_login_list, pwd, user, hostlist,
  	       (mb->sslflag||mb->tlsflag))){
  		dprint(9, (debugfile, "mm_login: found a password for user=%s to try\n", user));
  		return;
  	    }