IMAP4 protokol je protokol pouzivany k manipulaci se zpravami na postovnim serveru pres TCP/IP spojeni. Posledni verze IMAP protokolu je definovana v
http://www.ietf.org/rfc/rfc3501.txt. Narozdil od POP3 protokolu umoznuje:
telnet agent.zlutazimnice.cz 143M
Trying 81.95.102.223...
Connected to agent.zlutazimnice.cz.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION STARTTLS] Courier-IMAP ready. Copyright 1998-2004 Double Precision, Inc. See COPYING for distribution information.
0001 login testaccount@zlutazimnice.cz spatneheslo
0001 NO LOGIN failed.
0002 login testaccount@zlutazimnice.cz testovoheslo
0002 OK LOGIN Ok.
0003 select inbox
* FLAGS (\Draft \Answered \Flagged \Deleted \Seen \Recent)
* OK [PERMANENTFLAGS (\* \Draft \Answered \Flagged \Deleted \Seen)] Limited
* 1 EXISTS
* 1 RECENT
* OK [UIDVALIDITY 1126594605] Ok
* OK [MYRIGHTS "acdilrsw"] ACL
0003 OK [READ-WRITE] Ok
0004 fetch 1 flags
* 1 FETCH (FLAGS (\Seen \Recent))
0004 OK FETCH completed.
0005 fetch 1 body
* 1 FETCH (BODY (("text" "plain" ("charset" "us-ascii") NIL NIL "7bit" 64 3)("text" "html" ("charset" "us-ascii") NIL NIL "quoted-printable" 593 13) "alternative"))
0005 OK FETCH completed.
0006 fetch 1 full
* 1 FETCH (FLAGS (\Seen \Recent) INTERNALDATE "12-Sep-2005 05:48:36 +0200" RFC822.SIZE 2363 ENVELOPE ("Mon, 12 Sep 2005 05:46:31 +0200" "zkusebni mail #1" (("Honza Novak" NIL "kacerr" "developers.zlutazimnice.cz")) (("Honza Novak" NIL "kacerr" "developers.zlutazimnice.cz")) (("Honza Novak" NIL "kacerr" "developers.zlutazimnice.cz")) ((NIL NIL "testaccount" "zlutazimnice.cz")) NIL NILNIL"<20050912034833.7363A6EF3F@agent.zlutazimnice.cz>") BODY (("text" "plain" ("charset" "us-ascii") NIL NIL "7bit" 64 3)("text" "html" ("charset" "us-ascii") NIL NIL "quoted-printable" 593 13) "alternative"))
0006 OK FETCH completed.
0007 store 1 +flags (\Deleted)
* 1 FETCH (FLAGS (\Seen \Deleted \Recent))
0007 OK STORE completed.
0008 expunge
* 1 EXPUNGE
* 0 EXISTS
* 0 RECENT
0008 OK EXPUNGE completed
0009 list "" *
* LIST (\Unmarked \HasNoChildren) "." "INBOX"
0009 OK LIST completed
0010 select inbox
* FLAGS (\Draft \Answered \Flagged \Deleted \Seen \Recent)
* OK [PERMANENTFLAGS (\* \Draft \Answered \Flagged \Deleted \Seen)] Limited
* 0 EXISTS
* 0 RECENT
* OK [UIDVALIDITY 1126594605] Ok
* OK [MYRIGHTS "acdilrsw"] ACL
0010 OK [READ-WRITE] Ok
quit
quit NO Error in IMAP command received by server.
0011 quit
0011 NO Error in IMAP command received by server.
0011 logout
* BYE Courier-IMAP server shutting down
0011 OK LOGOUT completed
Connection closed by foreign host.