Subject: (UW)IMAP4, BSD/OS 4.0 and home directories

From: "Erik R. Leo" <[email-masked]>
Date: Thu, 3 Dec 1998 11:25:40 -0500 (EST)

Hi;

	I am having a strange problem with getting the UW IMAP (c-client)
server to check for mail in home directories.  I have followed the IMAP
documentation, and modifed src/osdep/unix/env_unix.c, function
sysinbox(), replacing:

     sprintf (tmp,"%s/%s",MAILSPOOL,myusername ());

with:

     sprintf (tmp,"%s/INBOX",myhomedir ());

but myhomedir() is returning with the first 12 characters of the home
directory lopped off (e.g., "/usr/home/user" becomes "er").  I have added
some syslog calls to track down where the truncation is occuring, and it
seems that the function loginpw() (in src/osdep/unix/log_bsi.c) is the
culprit.  More specifically, this function's interraction with the
auth_compat(3) routine auth_approve results in adding 12 to the *value* of
pw->pw_dir.

	I am using imap-4.4 on BSD/OS 4.0 patched through M400-017.  I
have reproduced the problem on earlier c-client IMAPs (including
imap-4.1.FINAL from the BSD/OS 4.0 contributed source CD-ROM), and I have
attemted to use the new, improved authenticate(3) interface (specifically
by replacing the call to auth_approve with a call to auth_approval), all
to no avail.  I had this modification working fine under BSD/OS 3.1, with
various versions of the c-client IMAP.

	I'm sending this message to the c-client mailing list and
bsd-users, as well as opening a ticket with BSDI support, but I'd
appreciate any advice or feedback the community has to offer.

-Erik
-- 
Erik R. Leo, Net Worker       SoVerNet
Tel:    +1(802)463-2111       Vermont's Sovereign Internet Connection
Fax:    +1(802)463-2110       Post Office Box 495, 5 Rockingham Street
Email:  [email-masked]       Bellows Falls, Vermont 05101

------------------------------------------------------------------
 For information about this mailing list, and its archives, see: 
 http://www.washington.edu/imap/c-client-list.html
------------------------------------------------------------------

---

From: Mark Crispin <[email-masked]>
Date: Thu, 3 Dec 1998 09:32:35 -0800 (PST)

On Thu, 3 Dec 1998 11:25:40 -0500 (EST), Erik R. Leo wrote:
> More specifically, this function's interraction with the

This seems to be a BSDI issue; it was BSDI that wanted me to use those calls
(e.g. auth_approve) instead of the standard UNIX authentication.  I have no
access to a BSDI system, and thus am completely dependent on what BSDI tells
me.

It sure sounds like a bug, though.  The ball's in BSDI's court, however;
either they can fix their libraries or recommend a workaround in the ckp_bsi.c
and log_bsi.c files so that they conform to c-client's interface
specifications in spite of the problem.

Until BSDI resolves this issue, I recommend that you use the bsi port instead
of bs3.  The bsi port is pretty much the same, except that it uses standard
UNIX authentication and login mechanisms.