Visual RFC.
ALL RFCs / RFC 9051
Read the RFC ↗
RFC 9051 / MECHANISM GUIDE

Session and mailbox states

01

Authentication and mailbox selection enable different commands.

RFC 9051 · § 3EXAMPLE
3 / 3
03
LOGOUT

End the session rather than using IMAP to send a message.

Session and mailbox statesAuthentication and mailbox selection enable different commands.Session and mailbox statesNOT AUTHENTICATEDauthenticateAUTHENTICATEDSELECT / EXAMINESELECTED: INBOXLOGOUTLOGOUT STATE

Key idea: The major states are not authenticated, authenticated, selected, and logout.

Terms

Look up a term in the glossary ↗

Rules & examples
  • The major states are not authenticated, authenticated, selected, and logout.
  • Successful authentication enters AUTHENTICATED; successful SELECT or EXAMINE enters SELECTED. Message-affecting commands require a selected mailbox.
  • IMAP accesses mail; SMTP submission is a separate protocol.

This drawing follows ordinary successful authentication then mailbox selection. PREAUTH can start in AUTHENTICATED. A failed selection or successful CLOSE/UNSELECT returns to AUTHENTICATED; logout can end a session from any active state.

Sources
Protocol participantThreat or exceptionProtocol controlSimplified drawings · precise section references
New to this? Start hereA quick picture + helpful background

The envelope and the letter do different jobs.

Mail transport moves a message between servers. The message format describes its contents. Authentication adds checks; it does not make every message safe.

Helpful first, if these ideas are unfamiliar

These pictures are analogies to help you learn. The linked RFC explains the actual rules.

Related RFCs and changes

“Updates” changes part of an earlier RFC. “Obsoletes” replaces it. This list shows selected related documents.

What changed
RFC 3501 / IMAP4rev1RFC 9051 Appendix E

IMAP4rev2 folds in extensions including IDLE, MOVE, UIDPLUS, and ESEARCH, and adds support for 64-bit message and body-part sizes.

Read the updated RFC section ↗

All chapters in RFC 9051

Drawing view

Scroll the drawing to see every part. Playback controls stay above it.

RFC 9700 / CHAPTERS

Chapters

For full details, tables, algorithms, and exceptions, read the original RFC.

RFC status and corrections ↗