Published on: January 24, 2017 by Muhammed Ijaz
Emails have become an unavoidable part of our life. The simplicity of sending and receiving an email is the major reason for its popularity. If you want to send a mail you just need the receiver’s email ID, as a result, it is one of the easiest means for communication.
However, most of us are still unaware of the how email works. By knowing the working of Emails we can easily troubleshoot the common issues we face while using Emails.
The ground reality is that the working of emails is not as simple as it may seem. There are a number of complex activities running on background when we use mail communication.
Before jumping into the working of emails lets see some very basic terms associated with it.
Mail User Agent, Program for viewing, reading, composing Emails.
eg: Webmail, MS Outlook, Mozilla Thunderbird, Apple Mail, elm, pine, mutt
Mail Transfer Agent, Program for Routing the mails. It accepts mails either dispatched by an MUA for delivery or from MDA for reception
eg: Exim, Sendmail, Postfix, Zimbra, QMail
Mail Delivery Agent, which performs the actual delivery.
eg: mail.local, procmail
Since we have seen the basic agents involved in Email communication, we can see how these “Agents” help us in mail communication.
The image shown below represents the whole process.
Since we have seen the basic working of emails, let us dive deeper into the working now.
First of all with the aid of MUA user composes the Email.
This involves mainly three parameters, such as the Outgoing Mail server name, Email address, and the password. Once the MUA authentication of those directives are complete, the message is passed over to the MTA for further process.
For instance, consider the sending Email address as firstname.lastname@example.org and the recipient as email@example.com. The sending MTA checks where the recipient domain recipient.com resolves to. It asks the DNS server on the recipient.com network for the hostname of the mail server. The MX (Mail Exchanger) record in DNS identifies the Host Name of the mail server. The DNS server for recipient.com returns the value of the MX record, which is the hostname of the mail server, something like, mail.recipient.com.
The sending MTA now asks the DNS server on the recipient.com network for the address of the mail server host (mail.recipient.com). The A record in DNS maps the host name to an IP address. The DNS server for recipient.com returns the value of the A record for the mail server host (mail.recipient .com), which would be some IP address.
The sending mail server connects to the receiving mail server’s IP address and checks whether it can connect to the SMTP port of the recipient mail server and if it can, then it will deliver the E-mail.
Category : General, Linux