We accept

Email Protocol: SMTP, POP, and MIME

Email protocol governs the interactions between email clients and machines. An Email protocol is a typical method which is employed at each end of the communication route either server part or client side, to be able to transfer information properly. End user is required to use a mail client to gain access to to the mail server, by using variety of email protocols, the email customer and server can only just exchange their information with each other. Three examples of Email protocol are:

  1. Simple Mail Transfer Protocol (SMTP)
  2. Post Office Protocol(POP)
  3. Multipurpose Internet Mail Extensions(MIME)
  1. Simple Mail Transfer Protocol(SMTP)

Simple Mail Copy Process (SMTP) transmits electronic mail (email) within different hosts in the Section of Security Internet protocol suite. Email machines and other mail transfer agents use SMTP to send and receive communications, while SMTP usually used by consumer side's email request to send information to the e-mail server for relaying only. For receiving messages, client area would usually use POP standard protocol which will be introduced at another part. Examples of email client that used SMTP to send text messages are webmail systems: Hotmail, Gmail and also Prospect, Microsoft Exchange etc. SMTP listens on TCP process well-known port 25.

Functions of SMTP:

To enable the client part to send email communication to a recipient (an email address which already exist), SMTP would perform the next functions:

  1. User authentication
  • To verify the sender who is using SMTP server to send an email message has the right to do so.
  1. User notification
  • After providing the meaning to the vacation spot, SMTP will check whether the concept has been successfully delivered.
  • If the note does not provided efficiently, SMTP notifies sender by using one announcements and the meaning that had not been successfully provided will be supplied back to the sender.

Advantages of SMTP:

  1. Simplicity

SMTP is the easiest way to send an electric email between various personal computers in a specific network. So long as there is a receiver destination and a sender who send the meaning, the message will be send to the vacation spot. The meaning will go through an easy process from SMTP server to the exchange server for the receiver's computer.

  1. Quick Email Delivery

As we known SMTP is the simplest way to transmit a note, electronic mails can be dispatched efficiently by using SMTP. As long as the condition of the email server is good, the text messages that are dispatched will reach to the recipients as quick as it can be.

  1. Reliability

When the communication has didn't deliver, one meaning will be sent to notify the sender and the note that didn't deliver will be repaid to the sender. In this case, sender does not have to be concerned that the communication send will failed to delivered, since when the note is didn't delivered, sender can make to resend the note until the meaning is finally sent to the recipient efficiently.

Limitation of SMTP:

  1. Additional administrative overhead

Original SMTP identifies clients by using the IP addresses, but it is only available when the email services are provided by the same Internet server service provider that supplied the bond. Therefore, an extension known as" SMTP-AUTH" is required to verify the senders of the communications.

  1. Required to create security
  2. Required expertise
  1. Post Office Protocol(POP)

Post Office Protocol (POP) is a Internet standard standard protocol in the application layer which allows email clients to retrieve email messages from a remote mail server. From the types of POP that is developed, current standard that used in most of your client and server email communication architecture is version 3 of POP also written as POP3. POP3 server listens on TCP protocol well-known port 110. It uses the TCP/IP process stack for network interconnection and works together with SMTP for end-to-end email communication. In this case, POP is sensible to "pull" the announcements from the server and SMTP will "push" the emails to the server.

Function of POP:

  1. Retrieve message from an ISP and whether to erase or not to delete it on the server, is determined by users' decision.
  2. Detect whether new communication has arrived however, not retrieving it from the server, meaning the information will be stored at the server before individual choose to retrieve it from the server.
  3. To see whether the message will probably be worth retrieving, POP will peek at the few sentences of the message before retrieving it.

Advantages of POP:

  1. Once the messages have been retrieved to the client computer, it is visible with or with no internet connection including the attachment combined with the message.
  2. User can make whether to delete or not to delete the emails that already retrieved from the server.
  3. User can choose to save a duplicate of a few of the important text messages by choosing never to delete the information from the POP server.

Disadvantages of POP:

  1. Occupied a lot of hard disk drive areas in computer as the email retrieved from the server are all store into the hard disk storage area.
  2. Not accessible from other machine. Nowadays, people uses multiple devices to access to one email account, but not with POP, all communications are downloaded into one and only one PC. In order to read that specify message, user can only just use the Personal computer which used to down load the messages to see it.
  3. Messages stored at local disk drive are susceptible to data reduction or even security hazards. As those messages stored at local drive are erased from the server and stored at only one PC at a time, it is more dangerous when the Personal computer suffered virus invasion or data corrupted.
  1. Multi-purpose Internet Email Extension(MIME)

MIME is an extension that allows users to make use of the standard protocol to send different sorts of documents on the Internet, for example: music file, image record (PNG, GIF, JPEG), video recording or even program programs. SMTP standard protocol only managed ASCII text, this means, only ASCII texts can be send through the standard protocol. Media type of content in email is detailed by MIME type, a few of the examples for MIME types are:

  • Plain word: txt/plain
  • Java applets: request/x-java-applet
  • Adobe PDF documents: software/ pdf

Advantages of MIME:

  1. Allows mail emails is made up not only ASCII word.

Old version of Internet email standard allows only ASCII characters messages, announcements not surpass 1000 characters etc. But with MIME, it allows additional fields for mail communication utilizing the MIME headers that express new types of content and organization for announcements.

MIME allows mail messages to contain the following:

  • Multiple objects within a message.
  • Unlimited length texts.
  • Other than ASCII characters, it also allows non-English communications.
  • Message that comprise multiple types of font.
  • Application designate or even binary files.
  • Audio, Image, Training video and other multimedia system attachment in the mail message.
  1. MIME header can help consumer PC to search for the suitable software software to open up the attachment or file include in the mail announcements.

Disadvantages of MIME:

  1. Some compound types are believed as a credit card applicatoin when they are nor for example "application/pdf".

Diagrams below show how consumer and server send and get text messages via SMTP and POP protocols, also the way the multipurpose internet email extension works:


How to use the next email protocols (SMTP, POP, MIME) with ASP. NET?

One way to use the talked about email protocols with asp. net is using System. Online namespaces. It consists of classes that provide simple programming user interface for several number of network protocols, compose Email and send it, it also consist of representation of multipurpose internet email exchange (MIME) headers. Besides, it also can usage of network traffic data and peer-to-peer networking function.


Inside System. Net, there's a namespace called System. Net. Mail, it contains classes that we needed which is to send email messages to a simple mail transfer process (SMTP) server for this to be delivered. Classes include in this namespaces are for example: an Attachment class which allowed end user to include an attachment into the email, MailMessage school represents the email message that can be sent by using the SmtpClient class, since there is also a class which allowed end user to send a contact utilizing the SMTP.

List of all the classes in System. Net. Email namespace will be contained in Appendix A.

To actually send an email using SMTP, we will require these pursuing items:

  • The SMTP number server that people use to send email.
  • A port amount, which often we use port number25.
  • User name and password for authentication purpose.
  • An email of sender and recipients.
  • The concept content.

Once we have accessible SMTP server, it's time to send our email communication! Firstly we should create a clear page which contains the example coding shown:

Next we can choose to send the email to several person at the same time, by adding email address to the "To" collection as shown below:

After that we can set the name of the sender, this will be shown combined with the sender email address to the recipient after the email has been received. For instance, we can do that:

Next, we may use the CC and BCC fields in the e-mail messages, for example:

Other than that, we can also arranged priority of a contact meaning, by using one of the technique provided in the System. Net. Mail class:


To get on a POP server, we need to use System. Net. Sockets namespace. Classes that people may use from the machine. Net. Sockets namespace are for example TcpClient and NetworkStream.

Firstly, we will need a simple aspx page which involves several textfields that allow customer to get into the username and password.

To initiate the bond to POP3 server, we will use the machine. Net. Sockets. For example, after user go into their username and password, and then there's a on click event of the button as shown in the following header:

Next, we will send the username and password to the server, and the server response will be displayed:

If the account are valid and effectively verified by the POP server, we will receive a response and then learn to retrieve a list of announcements from the server. We will request for using the LIST demand and display each message that people loop through:

At last, we have to close the bond to the server. In cases like this, QUIT command has come to use, and then server response will be display:


Similar with applying SMTP into asp. net, we may use the classes within System. Net. Email namespace to apply MIME into asp. net. There is certainly one namespace called System. Net. Mime which retains the types that used to signify MIME headers. These kinds are use along with the types in System. Net. Mail namespace whenever a SmtpClient course send an email with connection. Data of MIME is displayed by Attachment course which we just talked about in the machine. Net. Email part. Here are some exemplory case of classes contained in the System. Net. Mime:




This signifies a Content Type header in MIME standard protocol.


Media type information for the attachment included in an email message.

MediaTypeNames. Image

This will specifies the type of image file fastened into a contact communication, for example, . png, . jpeg and so on.

For the full set of classes included in System. Net. Mime, please make reference to Appendix B.

More than 7 000 students trust us to do their work
90% of customers place more than 5 orders with us
Special price $5 /page
Check the price
for your assignment