15.4 SMTP
The Simple Mail Transfer Protocol (SMTP) is a simple protocol. Individual commands are in the form of ASCII text (similar to the Telnet protocol). Therefore, it is easy to use the Telnet program, for example, to send an email using the SMTP protocol.
The client uses the TCP protocol to establish a communication channel to a server on a well‑known port 25. The client will enter commands in this channel, and the server will reply with a three-digit code followed by an error description text.
Commands entered by the client are four-character words that are not case sensitive. A command may be followed by a parameter separated by a space. The command will end with the end of the line (CR LF).
The principle of the SMTP protocol may be shown by an example of sending an email using the Telnet program from Windows XP. (The highlighted code indicates the client’s commands, and the remaining code indicates replies from the server.):
C:\> Telnet smtp.provider.com 25
220 dns...