Subject: IMAP on NT

From: "Gordon Watts (UW Seattle)" <[email-masked]>
Date: Mon, 20 Dec 1999 13:40:00 -0600

Hi,
  Last night I pulled the UW IMAP server down and built it for NT. I have it
running on a NT4.0 SP6 machine, using Outlook 2000 as a client. I was able
to build the server and also get it going running. I was able to connect to
with with Outlook, and create folders at the top level. I was able to figure
out how to alter the code to get it to place the mailbox on a different disk
as well.

  When I tried to create sub-folders I started having trouble (this may be
similar to the Netscape folder problems I saw mentioned on the list
archives). To create a top level folder that contains subfolders I have to
create the subfolder with a "\" on the end. So, for example, "foo\". The
shows up in my Outlook display for about a second or two and then
disappears. Very odd. If I look at the disk on the server it has correctly
created the folder, however. It is as if once Outlook created the folder it
then re-queried the server for the folder list, but the folder list didn't
contain the just-created folder (indeed, if I look at the Mailbox.lst file I
don't see the sub-folders listed there). Obviously, I have to be doing
something wrong.

  I also have a quick question about IMAP. I've used two IMAP servers
extensively before moving here to UW (besides Exchange). In both cases I was
able to put mail messages in any folder, no matter weather or not it
contained other folders. That is, I didn't have to create special root
folders. This was very nice, as I could let a mailbox folder grow
organically till it was too big, then create subfolders and refile the mail
in there (or, more likely, just leave it there and start filing the new
stuff). Is the fact that a IMAP folder that contains other mailboxes does
not contain other mail messages part of the IMAP definition or just this
server's implementation. Of course, the other downer, is that Outlook, at
least, expects that so that if I try to copy my 100 megs or so of mail over
I can't do it by a simple drag & drop operation. Oh well.

  Which brings me to my last question. If I wanted to change this behavior,
I'd do it by making every mailbox a directory, and in that directory put a
mbx file called "default" or something like that. Or make every mailbox file
end in ".mbx" and then a subdirectory with the same name could exist along
side. To make these modifications I would alter the mbx driver -- is that
right? Have others done such a thing?

  One last thing. When setting up the driver I was unable to make it run
correctly on my NT machine at first -- username/password was always failing.
Turns out the LogonUser system call was failing. Which was due to the
administrator's group not having the change process token priv enabled. I
didn't see that in the documentation (perhaps it was there??) and it might
save someone who didn't know what to look for sometime if it was indeed in
there. Also, the new Scheduled Task interface is much nicer way to run the
server automatically (at, say, machine boot time) instead of the "at"
interface.

  Thanks for any help!

	Cheers,
		Gordon.

-- 
------------------------------------------------------------------
 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: Mon, 20 Dec 1999 13:55:55 -0800 (PST)

Gordon,

I made a set of notes (see below) in response to your message.  I hope that
these are helpful for you.

-- Mark --

Mailbox.lst is the file that holds the subscription list.  New entries aren't
made to that file without an explicit "subscribe" operation.

I suggest that you try turning off the "subscribed folders only" option in
Outlook and see if that works better for you.

Whether or not a named object can be both a mailbox [*] or a directory depends
upon the implementation.  In c-client, it depends upon the mailbox format.  By
the way, "mailbox" is the correct IMAP term for an object that contains
messages.  The problem with "folder" is that it is frequently used to refer to
directories and is hence ambiguous.

The problem with doing as you suggest (making every mailbox a directory, and
in that directory put a mbx file called "default") is that this breaks the
correspondence between mailbox names and filesystem names.  Correspondence is
very desirable to people who use UNIX tooks to manipulate mailbox files as
well as c-client applications.

If you want to use Scheduled Tasks to start inetlisn, you need to set it up so
that it runs inetlisn as the system account (NT AUTHORITY\SYSTEM).  It
requires a fair amount of hackery to do this.  I'm surprised that someone
hasn't come up with a real inetd for NT that would address this issue.

The c-client documentation is pretty explicit that c-client is not a "plug and
play" application on NT; it is a programmer's workbench for developing
applications.  If you just want to bring up an IMAP server on NT, and don't
want to hack, then you're probably better off with one of the commercial
servers.