Architecture of Email SMTP, POP, IMAP, MIME 1 Email, or electronic mail, is a method of exchanging digital messages from an author to one or more recipients 2 Early email systems required the auth[.]
Trang 1SMTP, POP, IMAP, MIME
1
Trang 2 Email, or electronic mail, is a method of
exchanging digital messages from an author
to one or more recipients
Trang 3 Early email systems required the author and
recipient to both be online at the same time
Similar to instant messaging
3
Trang 4 Today’s email systems are based on a
store-and-forward model
Email servers accept, forward, deliver, and
store messages
Neither the users nor their computers are
required to be online simultaneously
Trang 5 An email consists of 3 components:
1. Envelope
2. Header
5
Trang 6 Envelope- The “envelope” of an email is
similar to a paper envelope for mail
It conceals the contents of the mail
Encrypts email into a data packet
Trang 7 Header- contains control information
including things like, sender address,
recipient address, timestamp, cc, bc, etc
Body – Text body of email
7
Trang 8 SMTP – Simple Mail Transfer Protocol
Internet standard for electronic mail
Trang 9 Network-based email was initially exchanged
on the ARPANET in extensions to the FTP
In the 1970’s SMTP grew out of these
standards
9
Trang 10 Email is submitted by a mail client(MUA, mail user agent) to a mail server(MSA, mail
submission agent) using SMTP
The MSA delivers the mail to its mail transfer agent (MTA)
Trang 12 SMTP is a connection-oriented, text-based
protocol in which a mail sender
communicates with a mail receiver by issuing command strings and supplying necessary
data over a reliable ordered data stream
channel
This channel is typically a Transmission
Control Protocol (TCP) connection
Trang 13 An SMTP session consists of commands
Trang 14 MAIL- command to establish the return
address, reverse-path, bounce address,
mfrom, or envelope sender
RCPT- command to establish a recipient of
Trang 16 Post Office Protocol (POP) is an
application-layer Internet standard protocol used by local email clients to retrieve email from a remote
server over a TCP/IP connection
POP has been developed through several
versions, with version 3 (POP3) being the
current standard
Trang 17 Virtually all modern email clients and servers support POP3.
POP3 along with IMAP are the two most
prevalent Internet standard protocols for
email retrieval
17
Trang 18 Supports simple download-and-delete
requirements for access to remote mailboxes
Although most POP clients have an option to
leave mail on server after download, email
clients generally connect, retrieve all
messages, store them on PC, delete from
server, and then disconnect
Trang 19 The POP3 service uses the SMTP service to
provide inbound message delivery as well as
outbound message sending for POP3 clients
Treats mailbox as one store, no concept of
folders
POP3 is the interface between email clients
and the “mail store”
19
Trang 21 The authentication store is the repository of
user information needed to authenticate the
user
The authentication module accesses the
authentication store to verify the credentials
submitted by the client to the POP3 service
21
Trang 22 The Mail Storage API is the common interface
to the mail store for all processes
The POP3 service, SMTP delivery service for
POP3, and POP3 Server Administrator use the API to access the mail store
Trang 23 The mail store uses the file system for
storage
Typically located on the same server as the
POP3 service, but should be located on a
different local or network volume to avoid
disk space problems
Even though contained in file system,
accessed by using Mail Storage Access API
23
Trang 24 The SMTP delivery service for POP3 is the
component that transfers email from the
SMTP service to the user mailboxes
The delivery service is notified by the SMTP
service when new email arrives
New email is delivered to the mail store by
means of the Mail Storage Access API
Trang 25 The POP3 Server Administrator is the
interface used by the tools to configure the
server, domains, and mailboxes
The server administrator accesses the mail
store through API to create or modify
domains and mailboxes
Modifications to the service itself are made
through calls to the administration interface
within the POP3 service
25
Trang 27 IMAP (Internet Message Access Protocol) is an application layer internet protocol that allows
an email client to access email on a remote
server
Again, IMAP along with POP3 make up the
two most prevalent Internet standard
protocols for email retrieval
27
Trang 28 Supports both online and offline modes of
operation
Email clients using IMAP generally leave
messages on the server until the user
explicitly deletes them
This allows for multiple clients to manage the same mailbox
Trang 29 Incoming email messages are sent to an
email server that stores messages in the
recipients email box
The user retrieves the messages with an
email client that uses on of a number of email retrieval protocols
29
Trang 31 Advantages over POP:
1. When using POP, clients typically connect to
the email server briefly, only as long as it
takes to download new messages
2. With IMAP, clients often stay connected as
long as the user interface is active and
download message content on demand
3. For users with many or large messages, this
can result in faster response times
31
Trang 32 Unlike POP where the currently connected
client can be the only client connected to the mailbox, IMAP allows for simultaneous access
by multiple clients
Provides mechanisms for clients to detect
changes made to the mailbox by other
currently connected clients
Trang 33 Most internet email is transmitted in MIME
format (discussed later)
IMAP allows clients to retrieve any of the
individual MIME parts separately and also to
retrieve portions of either individual parts or
the entire message
This allows clients to retrieve the text portion
of a message without retrieving attached files
or to stream content as it is being fetched
33
Trang 34 Through the use of flags, IMAP allows clients
to keep track of message states
Whether or not the message has been read,
replied to, or deleted
These flags are stored on server, so different clients accessing the same mailbox at
different times can detect state changes
Trang 35 IMAP allows for multiple mailboxes on the
server
IMAP clients can create, rename, and/or
delete mailboxes on the server, and copy
messages between mailboxes
Provides a search mechanism for searching a server for messages meeting a variety of
criteria
35
Trang 36 While IMAP remedies many shortcomings of
POP, this introduces additional complexity
Some problems can arise from this, such as
tying up server resources
Trang 37 Multipurpose Internet Mail Extensions (MIME)
is an internet standard that extends the
format of email to support:
1. Text in character set other than ASCII
2. Non-text attachments
3. Message bodies with multiple parts
4. Header information in non-ASCII character
sets
37
Trang 38 Originally designed for SMTP protocol.
Has grown beyond describing the content of
email and now often includes describe
content type in general, including for the
web, and as a storage for rich content in
some commercial products
Virtually all email is transmitted via SMTP in
MIME format
Trang 39 Mime uses headers as a way to describe the
structure of the email
Common MIME headers:
Trang 40 MIME-Version Ex: “MIME-Version: 1.0”
Required header indicating this message is to use the rules of MIME
Content-Type: used to specify the media type and subtype of data in the body of a message and to fully specify the native representation
of such data
Trang 41 Content-Transfer-Encoding: can have 2
different meanings
If the value is “base64” or “quoted-printable”, then the header indicates the encoding used
for this body part
If the value is “7bit”, “8bit”, or “binary”, then
the header indicates that there is no encoding the that this value indicates only the type of
content this body part contains
41
Trang 42 Content-ID: world-unique values that identify body parts, individually or as groups.
Necessary at times to distinguish body parts
and allow cross-referencing between body
parts
Trang 43 Content-Description: optional header used to add descriptive text to non-textual body
parts
Content-Disposition: provides information
about how to present a message or a body
part
When a body part is to be treated as an
attached file, the Content-Disposition header will include a file name parameter
43