Problem solve Get help with specific problems with your technologies, process and projects.

Using DavMail to access Exchange’s Outlook Web Access from any POP3/IMAP-compatible mail client

You can connect mail clients other than Outlook to an Exchange server using DavMail, a free open source application. Learn what settings need to be tweaked to be operational on Exchange in a Thunderbird or other open source mail client environment.

Time and again I have been asked: Is it possible to connect a mail client other than Outlook to an Exchange server? The short answer is “yes,” but it’s a roundabout process.

The easiest method involves hitching a third-party mail client that speaks IMAP to Outlook Web Access, by way of a proxy program, DavMail, which is a free and open source application. DavMail was written by Mickaël Guessant, and is available for multiple platforms (Windows, Mac, Linux). It allows you to access not just mail folders, but directories and calendars also — for instance, via Thunderbird with the Lightning extension or Apple’s iCal. The main requirement is that you have Outlook Web Access set up and running.

DavMail can be installed on multiple computers and used on each of them as a local proxy (e.g., many clients connecting from various external or private networks). But it can also be installed on a single machine (even the Exchange server) and used as a proxy connection for all your clients as long as that machine has clear access to OWA. Keep in mind that any communications between the client and the proxy are not encrypted by default, so you either need to encrypt the communications or make sure the network is secure.

Once you install DavMail, the most crucial part of the setup process is setting up the mail gateway, under the program’s “Main” tab in its settings window. This is the URL for your organization’s OWA page (typically http://server/owa).

Click on image for larger version

You should also check the port assignments that DavMail uses to accept incoming connections from your mail clients. By default these are set to values that shouldn’t clash with existing applications or the defaults used by non-proxied versions of the same protocols. Example: the default IMAP port is 143; DavMail’s local proxy port for IMAP is 1143.

The next task is to configure the client. This process will vary between clients, but generally you need to make sure that:

  1. The client always points to the proxy, and not the remote server. If you have the proxy running on the same machine, then the IMAP server name is generally just localhost.
  2. The username needs to be passed correctly. Depending on how you have OWA configured, this is either in the format [email protected] or domain\user. DavMail cannot infer what the proper domain name is by context; you have to pass it along explicitly.
  3. The outbound SMTP server should be also set to localhost (default port for DavMail is 1025), and should employ the same username (in the [email protected] format) and password that you use for your OWA account.
  4. Provide exactly the right base DN for your searches. This varies depending on your configuration; I’ve found that supplying ou=people was enough for searches to work properly for the Exchange server I was using. Again, the server specified on the client should be localhost, and the port should be the proxy’s LDAP port (by default, port 1389).
  5. Use the CalDAV protocol to access calendars with the following URL: http://localhost:1080/users/[email protected]/calendar,where [email protected] is your username and domain name as used above. When prompted for credentials, use the usual [email protected]/password combination. DavMail’s authors recommend using enabling calendar caching (if supported) to avoid long load times.

A remarkable amount of two-way synchronization is supported through DavMail. If you drag and drop a message from your local folders into a folder on the OWA server, for instance, the message will be copied to the appropriate folder on the remote server.

The DavMail site includes some fairly detailed walkthroughs for setting up the program and adding integration for calendaring and other functions. Unfortunately, while the text of the walkthroughs are in English, the screenshots for most of the applications are in French. The Thunderbird walkthrough is also not of much use, since they use a much older version than the current one for their demonstration.

ABOUT THE AUTHOR: Serdar Yegulalp has been writing about computers and information technology for more than 15 years for a variety of publications, including InformationWeek and Windows Magazine.


Dig Deeper on Outlook management

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.