IMAP: Difference between revisions

From miki
Jump to navigation Jump to search
(→‎Courier IMAP on Cygwin: moved to a dedicated page)
Line 27: Line 27:
=== Courier IMAP on Cygwin ===
=== Courier IMAP on Cygwin ===
See the page dedicated to [[Courier Cygwin]].
See the page dedicated to [[Courier Cygwin]].

== Testing IMAP ==
Here some [http://documents.made-it.com/imapcmd.html scripts] to test that an IMAP server is working properly.

* To quickly test an imap server using telnet use:
<div style="padding-left:2em;"><source lang=bash>
% telnet server 143
01 LOGIN username password
02 LIST "" * # show all available mailboxes
03 SELECT mailbox # mailbox: e.g. INBOX
04 LOGOUT
</source></div>
* To show the information about a mailbox:
<div style="padding-left:2em;"><source lang=bash>
% telnet server 143
04 STATUS mailbox (MESSAGES)
</source></div>
:Between <tt>()</tt> you can place one or more of the following: <tt>MESSAGES, UNSEEN, RECENT UIDNEXT UIDVALIDITY</tt>

* And one of the following commands to view a message (1 is the first message * is wildcard for all):
<div style="padding-left:2em;"><source lang=bash>
05 FETCH 1 ALL # All IMAP headers
05 FETCH 1 FULL # Full headers and body info
05 FETCH 1 BODY # Body
05 FETCH 1 ENVELOPE # Envelope
05 FETCH * FULL # All email
</source></div>

* To fully retrieve a message use:
<div style="padding-left:2em;"><source lang=bash>
06 UID fetch 1:1 (UID RFC822.SIZE FLAGS BODY.PEEK[])
</source></div>

Revision as of 08:08, 22 January 2009

IMAP servers

There are basically three main IMAP server solutions:

UW IMAP
IMAP server developped by the University of Washington. Uses a proprietory mailbox format mbx, which is more or less a binary version of the usual mailbox format. A binary package exists on cygwin, but it regularly suffers from locking problems. A patch exists to use maildir format though, but patch seems outdated.
Courier IMAP
Courier-IMAP is a fast, scalable, enterprise IMAP server that uses Maildirs.
Cyrus IMAP
Developped by Carnegie Mellon. Also uses a private mailbox format.

Courier IMAP

References

Courier IMAP on openSUSE

Binary package for Courier IMAP is available on openSUSE (package courier-authlib and courier-imap). However it conflicts with the default IMAP server, (UW IMAP), which must first be uninstalled.

Courier IMAP on Cygwin

See the page dedicated to Courier Cygwin.

Testing IMAP

Here some scripts to test that an IMAP server is working properly.

  • To quickly test an imap server using telnet use:
% telnet server 143
01 LOGIN username password
02 LIST "" *                 # show all available mailboxes
03 SELECT mailbox            # mailbox: e.g. INBOX
04 LOGOUT
  • To show the information about a mailbox:
% telnet server 143
04 STATUS mailbox (MESSAGES)
Between () you can place one or more of the following: MESSAGES, UNSEEN, RECENT UIDNEXT UIDVALIDITY
  • And one of the following commands to view a message (1 is the first message * is wildcard for all):
05 FETCH 1 ALL               # All IMAP headers
05 FETCH 1 FULL              # Full headers and body info
05 FETCH 1 BODY              # Body
05 FETCH 1 ENVELOPE          # Envelope
05 FETCH * FULL              # All email
  • To fully retrieve a message use:
06 UID fetch 1:1 (UID RFC822.SIZE FLAGS BODY.PEEK[])