Which Protocol is Used to Receive Mail?

SMTP (Simple Mail Transfer Protocol) is the protocol used to transfer emails and email attachments. There is a plethora of other transfer protocols, with IMAP and POP3 being the most popular among the remaining, SMTP, however, is widely used and accepted because of its simplicity.

What is a 'Mail Transfer Protocol'?


Protocol refers to a set of instructions executed while transferring data to the client-server from an organization's internal email exchange servers. These protocols help ensure that data packets transmitted are encrypted and free of malware. Every protocol has the same underlying motive - to ensure secure transmission of email and email attachments.

Simple Mail Transfer Protocol


SMTP was first introduced in the year 1982 by ISOC (Internet Society) and received its first update in the year 2008. SMTP servers commonly use TCP (Transmission Control Protocol) on Port 25. TCP is a connection-based communication protocol, facilitating the interchange of messages between devices in a network. SMTP, on the other hand, is only an improvised version of TCP, used exclusively for email exchange instead of simple data exchange.

How an Email Exchange Takes Place via SMTP


Every email exchange system consists of -

- SMTP client 
- Email client, and 
- SMTP Server


The exchange of email is performed using TCP. SMTP is end-to-end message encryption and delivery system.

- First, SMTP client where the emails will originate contacts the destination SMTP. The two SMTP servers initiate a connection, commonly known as 'handshake'. A handshake is the first authorized connection taking place between two SMTP clients.

- After the handshake, a mail transaction is initiated with a MAIL command. Emails that originate from the client SMTP also have a FROM field tagged to them (FROM command ensure that the message is delivered to the right mailbox).

- Mails are sent in a series of packets, each packet carrying a small share of the mail's total data. A single email attachment can be up to 25 MB in size. Even the most advanced TCP cannot transfer that much data in one packet. Packet size, in most networks, is limited to a few bytes per connection. Thus, a series of packets is required to transmit emails as simple as a "Hello".
 
When data has to be exchanged, it is broken down and encrypted into smaller containers before transmission, called data packets.
 

- The host will send a series of RCPT commands, each command containing an identifier and a data packet embedded into it. The receiver acknowledges successful/failed receipt of each RCPT command by sending back 250 OK on success and 550 NO on fail.

- The host, on receiving 250 OK, continues sending identifiers and resends the last identifier when it receives 550 NO.

- After the host has acknowledged all RCPTs, the sender SMTP sends the final DATA command, informing the receiver that the sender is about to complete the transfer. The destination SMTP reverts with 354 Start mail command. 354 Start tells the host it is ready to receive whatever data packets are remaining to complete the mail transfer.

The client will now send the mail data (line by line), terminating the transfer with a code which is often a combination of 5 characters randomly selected by the sender.

Closing the Session

Amid each RCPT connection, there is a moment of silence, during which no transfer is taking place. During this brief period of time, the client is on standby, awaiting data packets to arrive at PORT 25. If no identifier is received within a given time frame (generally a few milliseconds), the client will automatically close the connection and the mail transfer wizard will display an error.

The mail transfer protocols cannot be closed without relaying QUIT command back to the receiver. The email dialog is so programmed that it will always return an error unless it receives QUIT from the sender.

Was this answer helpful? #5 #5
 

Did We Miss Out on Something?

Relax, we have you covered. At Go4hosting, we go the extra mile to keep our customers satisfied. We are always looking out for opportunities to offer our customers “extra” with every service. Contact our technical helpdesk and we’d be more than happy to assist you with your Cloud hosting, Colocation Server, VPS hosting, dedicated Server or reseller hosting setup. Get in touch with us and we’d cover all your hosting needs, however bizarre they might be.

Submit your Query

  • I'm not a robot

Browse by ServicesBrowse by Services

Resource Library

What is Cloud Computing

Understand the term cloud computing, the ongoing trend, its playing field, future growth and how industry...

Myths about Cloud Computing

Cloud computing, in the recent years, has become a subject of significant discussion among the industry experts.

Download Now

Did We Miss Out on Something?

Relax, we have you covered. At Go4hosting, we go the extra mile to keep our customers satisfied. We are always looking out for opportunities to offer our customers “extra” with every service. Contact our technical helpdesk and we’d be more than happy to assist you with your Cloud hosting, Colocation Server, VPS hosting, dedicated Server or reseller hosting setup. Get in touch with us and we’d cover all your hosting needs, however bizarre they might be.

Submit Query

Please fill in the form below and we will contact you within 24 hours.