Extended SMTP
From Wikipedia, the free encyclopedia
Extended SMTP (ESMTP), sometimes referred to as Enhanced SMTP, is a definition of protocol extensions to the Simple Mail Transfer Protocol standard. The extension format was defined in RFC 1869 in 1995.
RFC 1869 established a structure for all existing and future extensions, to produce a consistent and manageable means by which ESMTP clients and servers can be identified and ESMTP servers can indicate supported extensions to connected clients.
[edit] Extensions
The main identification feature is for ESMTP clients to open a transmission with the command EHLO (Extended HELLO), rather than HELO (Hello, the original RFC 821 standard). A server can then respond with success (code 250), failure (code 550) or error (code 500, 501, 502, 504, or 421), depending on its configuration. An ESMTP server would return the code 250 OK in a multi-line reply with its domain and a list of keywords to indicate supported extensions. An RFC 821 compliant server would return error code 500, allowing the ESMTP client to try either HELO or QUIT.
Each service extension is defined in an approved format in subsequent RFCs and registered with the IANA. The first definitions were the RFC 821 optional services - SEND, SOML (Send or Mail), SAML (Send and Mail), EXPN, HELP, and TURN. The format of additional SMTP verbs was set and for new parameters in MAIL and RCPT.
Some relatively common keywords (not all of them corresponding to commands) used today are:
- 8BITMIME — 8 bit data transmission, RFC 1652
- ATRN — Authenticated Turn, RFC 2645
- AUTH — Authenticated SMTP, RFC 2554
- CHUNKING — Chunking, RFC 3030
- DSN — Delivery status notification, RFC 1891
- ETRN — Extended Turn, RFC 1985
- HELP — Supply helpful information, RFC 821
- PIPELINING — Command pipelining, RFC 2920
- SIZE — Message size declaration, RFC 1870
- STARTTLS — Transport layer security, RFC 3207
With RFC 821 made obsolete by RFC 2821 in 2001 the ESMTP format was restated in RFC 2821. Support for the EHLO command in servers was made a "MUST", superseding the original HELO, which became a required "fallback".
Non-standard, unregistered, service extensions can be used by bilateral agreement, these services are indicated by an EHLO keyword starting with "X", and with any additional parameters or verbs similarly marked.
Although commands are listed in upper case in this article, it is not necessary and for a SMTP server to require so is a violation of RFCs 821 and 2821. The MUST is for commands to be in US-ASCII and terminated by <CRLF> or <SP> and parameters.
[edit] See also
[edit] External links
- IANA registry of mail parameters includes service extension keywords