Friday, May 26, 2006

Developing with Dwarf, the 100percent Java IMAP Server

I've recently been working on integrating a webmail client with our uPortal installation. The consensus is that the best IMAP webmail clients seem to be written in PHP (SquirrelMail and Horde IMP).

The idea is that we achieve single sign-on between our portal and webmail client via the JASIG CAS authentication broker. I'm planning to use ESUP's phpCAS.

My development environment is currently Win2K, I discovered a really nice set of 100% Java e-mail servers (part of the Dwarf Server Framework) these are ideal for IMAP/SMTP testing purposes.

Usually to CASify a proper Unix IMAP server you need to install a PAM CAS module. Although there are some free windows IMAP/SMTP servers around, from what I have seen, most of them don't support pluggable authentication mechanisms. The idea of porting a Unix IMAP server with PAM authentication to windows via Cygwin is enough to give me nightmares!

I had a play with the Dwarf IMAP Server and I have found that it more than suits my purposes for development. Obviously I won't be recommending that we move to using the Dwarf IMAP server in production; I'd no more suggest this than I'd install my washing machine onto the top shelf of my bookcase. Platform portability has it's place but for mission critical systems like e-mail then native C IMAP servers are still essential! The Dwarf Server Framework is not open source but it is free to use. The nice thing about the Dwarf IMAP server is that since it is written in Java I can fairly easily add my own authentication mechanisms, I found Dwarf very easy to CASify.

Until the Apache James project comes up with a stable and easy to install open source IMAP server, Dwarf will do very nicely.


Mark McLaren said...

Hi Mark!

i have to implement web based mail client.. i need an Mail server that supports imap protocol, i decided to use Dwarf Mail Server...

what is my question

How do i add the user and create the MailBox for that user in Dwarf Mail Server... please help!!!
Note: Comment imported. Original by Ram at 2006-09-27 12:03

Mark McLaren said...

The default mail user is joe with a password of asdf. Security in the DWARF Framework is configured via JAAS. The default login configuration for all DWARF services is called SK.gnome.dwarf.auth.login.PlaintextLoginModule.

The PlaintextLoginModule makes use of which contains username and encoded passwords. You can add new users and passwords to this file and create the encoded passwords using the default encoding mechanism SK.gnome.dwarf.auth.login.MD5PasswordEncoder.

By default any authenticated user will have an mail server account automatically created when they login for the first time.

Note: Comment imported. Original by markmc website: at 2006-09-27 19:40