SMTP

Synonym Simple Mail Transfer Protocol Generally refers to SMTP

Introduction

SMTP is a relatively simple text-based protocol. On one or more recipients of a message above it (in most cases are confirmed), then the message text is transmitted. You can test an SMTP server very simply through the Telnet program. SMTP uses TCP ports 25. To determine an SMTP server for a given domain name, you need to use the MX (MAILEXCHANGE) DNS.

The early SMTP began to be widely used in the early 1980s. At that time, it was only a supplement to UUCP, and UUCP is more suitable for processing emails between machines that handle intermittent connections. Instead, SMTP works best in the event of semating and receiving machines in the connection of continuous connection.

Sendmail is one of the earliest mail transport agents using SMTP. By at least 50 programs in 2001, the SMTP is implemented as a client (sender of the message) or a server (the recipient of the message). Some other popular SMTP server programs include Philiphazel's EXIM, IBM's Postfix, D.J.Bernstein's QMail, and MicrosoftExchangeserver.

Since this protocol is started based on pure ASCII text, it is not good in binary files. Standards such as MIME are developed to encode binary to transfer them through SMTP. Today, most SMTP servers support 8-bit MIME extensions, which makes the transfer of binary files almost as simple as plain text.

SMTP is a "push" protocol that does not allow "pull" to "pull" from the remote server as needed. To do this, the mail client must use POP3 or IMAP. Another SMTP server can trigger a send on SMTP using ETRN.

Function

SMTP is a set of rules for transmitting mail from source addresses to destination addresses, and controls the transfers of letters. The SMTP protocol belongs to the TCP / IP protocol, which helps each computer find the next destination when sending or transferring the letters. With the server specified by the SMTP protocol, we can send E-mail to the server's server, and the whole process takes only a few minutes. The SMTP server is an email that follows the SMTP protocol to send or transfer users.

SMTP

SMTP is a protocol that provides reliable and effective email transmission. It is a mail service built on the FTP file transfer service, mainly used to transmit mail information between systems and provide notifications related to letter. One of the important features of the

SMTP is that it can transfers the message across the network, that is, "SMTP Mail". Using SMTP, mail transmission between the processing machines on the same network can be implemented, or mail transmission between a processor and other networks can be implemented by a repeater or gateway. The mail swap server with the Domain Name Service System (DNS) function can also be used to identify the next hop IP address of the transfer message.

Working process

SMTP protocol work procedure can be divided into the following three processes:

(1) Establishment: At this stage, SMTP customer requests Establish a TCP connection with the 25-port of the server. Once the connection is established, the SMTP server and the customer began to advertise their domain names while confirming the other party's domain name.

(2) Mail Transfer: Using the command, SMTP client transmits the source address, destination address, and the specific content of the message to the SMTP server, the SMTP server performs the corresponding response and receives the mail.

(3) Connection Release: The SMTP client issues an exit command, the server responds after processing the command, and then close the TCP connection.

SMTP communication example

The following is a description by an instance. In this example, it is assumed that the message is sent from the sender email box named PANWEI@163.com (running the SMTP customer process, specifically displayed as c) to the recipient electronic mailbox named network@xmu.edu.cn (Run the SMTP server process, specifically displayed as s), the specific commands and response information is as follows: telnetwww.example.com 25 It opens a SMTP connection from the transmitted machine to the host www.example.com.

 s: (Note: Waiting for the 25th port of the TCP, the port corresponds to the SMTP service) C: (Note: Open the connection with the server) S: 220 xmu. EDU. CN SMTP Service Ready (note : The server's TCP connection Ready) C: Helo 163. COMS: 250 xmu. Edu. from: s: 250 0kc: rcpt to: s: 250 0kc: DataS: 354 Start Mail Input; End with.c: ... Sends Body of Mail Message..c: ... dear xxx. . C:. S: 250 OKC: Quits: 221 xmu. EDU. CN Service Closing Transmission Channel 

The above is a simple SMTP exchange process, including connection establishment, message transfer, and connection release three specific processes : First establish TCP connection, SMTP calls the TCP protocol No. 25 port listen to the connection request, the client sends the Helo command to identify the sender's own identity, the server responds. Then, the client sends a MAII) command, the server is in OK as II, indicating that the preparation is received. The client sends the RCPT command to identify the recipient of the email, you can have multiple RCPT lines, ie, a message can be sent to multiple recipients at the same time. The server side indicates whether it is willing to receive emails for the recipient. After the negotiation is over, the client uses the data command to represent the end of the input content. Finally, any end of the control interaction can choose to terminate the session, and the Quit command is issued for this, and the other end is responded to the command 221, indicating that the connection will close the connection.

The "2500K" meaning of the server side during the SMTP exchange process is everything. Like other protocols, the program reads only the abbreviation command and the three numbers starting at each line, and the remaining text is used to help user debug mail software. When the command is successful, the server returns code 250. If it fails, return code 550 (command cannot be identified), 451 (error is handled), 421 (not available), 421 (unavailable), 354 indicates start information input. .

SMTP Limitations Performance in only a message that can only send ASCII code format, does not support Chinese, French, German, etc., and it does not support voice, video data. Supplements SMTP through the MIME protocol. MIME uses the network virtual terminal (NVT) standard, allowing non-ASCII code data to be transmitted via SMTP.

SMTP Safety and Spam

One of the limitations of the initial SMTP is that it does not have a mechanism for authenticating the sender. Therefore, SMTP-Auth extension is then defined.

Despite the identity authentication mechanism, spam is still a major issue. However, due to the network effect brought by a huge SMTP installation, the big knife has a large-scale modification or complete replacement SMTP is considered unrealistic. The InternetMail2000 is a suggestion solution for an alternative SMTP.

therefore, some auxiliary protocols work with SMTP appear. The anti-spam research team of IRTF is studying some suggestion to provide simple, flexible, lightweight, upgraded source authentication. The most likely that the recommended solution is the sender policy framework agreement.

Related Articles
TOP