NOTE: Using software to mass-download the site degrades the server and is prohibited.
If you want to read The TCP/IP Guide offline, please consider licensing it. Thank you.

The Book is Here... and Now On Sale!

Searchable, convenient, complete TCP/IP information.
The TCP/IP Guide

Google
Web TCP/IP Guide






Table Of Contents  The TCP/IP Guide
 9  TCP/IP Application Layer Protocols, Services and Applications (OSI Layers 5, 6 and 7)
      9  TCP/IP Key Applications and Application Protocols
           9  TCP/IP File and Message Transfer Applications and Protocols (FTP, TFTP, Electronic Mail, USENET, HTTP/WWW, Gopher)
                9  TCP/IP Electronic Mail System: Concepts and Protocols (RFC 822, MIME, SMTP, POP3, IMAP)
                     9  TCP/IP Electronic Mail Delivery Protocol: The Simple Mail Transfer Protocol (SMTP)

Previous Topic/Section
SMTP Communication and Message Transport Methods, Client/Server Roles and Terminology
Previous Page
Pages in Current Topic/Section
12
3
4
Next Page
SMTP Mail Transaction Process
Next Topic/Section

SMTP Connection and Session Establishment and Termination
(Page 3 of 4)

Connection Establishment Using SMTP Extensions

The SMTP extensions defined at first in RFC 1425 and then in subsequent standards up to RFC 2821 define an alternative “hello” message for the client to use: EHLO (extended hello). An SMTP sender supporting SMTP extensions (and most do) uses EHLO instead of HELO in response to the 220 greeting. This serves both to say “hello” to the SMTP receiver, and to tell it that the sender supports SMTP extensions.

If the SMTP receiver supports the extensions, it replies back with the usual 250 reply, as well as a series of extra 250 responses. Each of these lists an EHLO keyword that indicates a particular SMTP extension the receiver supports. If the receiving server doesn't support the extensions, it will reject the EHLO command with a 500 reply code (“syntax error, command not recognized”). This tells the SMTP sender that it cannot use extensions; it will then either issue a conventional HELO command, or QUIT the connection if it requires the SMTP extensions to be present. (In practice, it is rare for a server to require the use of SMTP extensions.)

Here's the same example as above, but using EHLO. The sender says:

EHLO smtp.sendersite.org

Assuming “mail.receiversplace.com” supports the SMTP extensions, a typical reply might be:

250-mail.receiversplace.com Hello smtp.sendersite.org, nice to meet you.
250-SIZE
250-DSN
250 PIPELINING

Each of these additional replies identifies a particular SMTP extension supported by “mail.receiversplace.com”; in this case, message size declaration (“SIZE”), delivery status notification (“DSN”) and command pipelining. (The dashes after the “250” indicate a multiple-line response to a command.)

Once the HELO or EHLO command has been sent and the receiving device has responded, the session is initiated. Further commands can be sent by the sending SMTP server to the responding server. These usually take the form of e-mail message transfer transactions using the process described in the following topic, and other command/reply exchanges as needed.


Previous Topic/Section
SMTP Communication and Message Transport Methods, Client/Server Roles and Terminology
Previous Page
Pages in Current Topic/Section
12
3
4
Next Page
SMTP Mail Transaction Process
Next Topic/Section

If you find The TCP/IP Guide useful, please consider making a small Paypal donation to help the site, using one of the buttons below. You can also donate a custom amount using the far right button (not less than $1 please, or PayPal gets most/all of your money!) In lieu of a larger donation, you may wish to consider purchasing a download license of The TCP/IP Guide. Thanks for your support!
Donate $2
Donate $5
Donate $10
Donate $20
Donate $30
Donate: $



Home - Table Of Contents - Contact Us

The TCP/IP Guide (http://www.TCPIPGuide.com)
Version 3.0 - Version Date: September 20, 2005

© Copyright 2001-2005 Charles M. Kozierok. All Rights Reserved.
Not responsible for any loss resulting from the use of this site.