Overview
• Introduction to SMTP
• History of Smtp
• General features of SMTP
• Sendmail
• Relays And Gate ways
• How SMTP works
• Limitations in SMTP
• Example of SMTP
3
4
Composes, reads,
replies to
,forwards and
handles mailboxes
Transfers mails
from one host to
another
Collects mail
and delivers to
user agent
Transfers mails
from one host to
another
Collects mail
and delivers to
user agentIntroduction…
Introduction to SMTP
• SMTP is an Internet standard for electronic mail.
• SMTP is the protocol in widespread use today.
• It is the actual protocol used to transfer mail from MTA to
MTA.
• MTA: Mail Transfer Agent .... A program that actually
routes and delivers mail.
• MUA: Mail User Agen t ... A program that is used to
access mail after delivery.
• The objective of SMTP is to transfer mail reliably and
efficiently.
History of SMTP
• The SMTP specification originally started with the Mail
Transfer Protocol in 1980
• It evolved into Simple Mail Transfer Protocol (SMTP) in 1981
• Specified in RFC 821
• Most recent RFC is 2821
• First and most important implementation is sendmail
General Features
• Independent of underlying transmission subsystem.
• Just needs a reliable ordered data stream channel.
• Operates over TCP port 25.
• Uses an request-response protocol that is useful to human
readers (SMTP commands).
• SMTP sessions are stateful, with both parties carefully
maintaining a common view of the current state.
8
Sendmail
Mail Transfer Agent [MTA] : is a computer program or software agent
that transfers electronic mail messages from one computer to another.
• Sendmail is a MTA
• Supports several mail transfers including SMTP
• Pro’s
• Can perform header rewriting, mail routing
• Extensive support available
• Con’s
• Not secure
• Code is bulky [compared to other MTA’s such as qmail]
9
Message transfer…
SMTP is a push
protocol
10
• SMTP server can also
assume the role of a
“relay”
• SMTP mail gateways
are used to transport
mail prepared by a
protocol other than
SMTP
Relays and Gateways
SMTP supported
Non-SMTP
supported
11
Link Layer PCI IP-PCI
Keyword: argument(s)
Command format:
Response format:
3-digit status code [textual information]
How SMTP works?
Link Layer PCI IP-PCI TCP-PCI SMTP command/responseTCP-PCI SMTP command/responseTCP-PCI SMTP command/response
12
How SMTP works : Status Codes
The Server responds with a 3 digit code that may be followed
by text info
– 2## - Success
– 3## - Command can be accepted with
more information
– 4## - Command was rejected, but error
condition is temporary
– 5## - Command rejected, Bad User!
13
Limitations in SMTP
• Only uses NVT 7 bit ASCII format
– How to represent other data types?
• Susceptible to misuse (Spamming,
faking sender address)
SMTP transport example
Simple mail transfer protocol

Simple mail transfer protocol

  • 2.
    Overview • Introduction toSMTP • History of Smtp • General features of SMTP • Sendmail • Relays And Gate ways • How SMTP works • Limitations in SMTP • Example of SMTP
  • 3.
  • 4.
    4 Composes, reads, replies to ,forwardsand handles mailboxes Transfers mails from one host to another Collects mail and delivers to user agent Transfers mails from one host to another Collects mail and delivers to user agentIntroduction…
  • 5.
    Introduction to SMTP •SMTP is an Internet standard for electronic mail. • SMTP is the protocol in widespread use today. • It is the actual protocol used to transfer mail from MTA to MTA. • MTA: Mail Transfer Agent .... A program that actually routes and delivers mail. • MUA: Mail User Agen t ... A program that is used to access mail after delivery. • The objective of SMTP is to transfer mail reliably and efficiently.
  • 6.
    History of SMTP •The SMTP specification originally started with the Mail Transfer Protocol in 1980 • It evolved into Simple Mail Transfer Protocol (SMTP) in 1981 • Specified in RFC 821 • Most recent RFC is 2821 • First and most important implementation is sendmail
  • 7.
    General Features • Independentof underlying transmission subsystem. • Just needs a reliable ordered data stream channel. • Operates over TCP port 25. • Uses an request-response protocol that is useful to human readers (SMTP commands). • SMTP sessions are stateful, with both parties carefully maintaining a common view of the current state.
  • 8.
    8 Sendmail Mail Transfer Agent[MTA] : is a computer program or software agent that transfers electronic mail messages from one computer to another. • Sendmail is a MTA • Supports several mail transfers including SMTP • Pro’s • Can perform header rewriting, mail routing • Extensive support available • Con’s • Not secure • Code is bulky [compared to other MTA’s such as qmail]
  • 9.
  • 10.
    10 • SMTP servercan also assume the role of a “relay” • SMTP mail gateways are used to transport mail prepared by a protocol other than SMTP Relays and Gateways SMTP supported Non-SMTP supported
  • 11.
    11 Link Layer PCIIP-PCI Keyword: argument(s) Command format: Response format: 3-digit status code [textual information] How SMTP works? Link Layer PCI IP-PCI TCP-PCI SMTP command/responseTCP-PCI SMTP command/responseTCP-PCI SMTP command/response
  • 12.
    12 How SMTP works: Status Codes The Server responds with a 3 digit code that may be followed by text info – 2## - Success – 3## - Command can be accepted with more information – 4## - Command was rejected, but error condition is temporary – 5## - Command rejected, Bad User!
  • 13.
    13 Limitations in SMTP •Only uses NVT 7 bit ASCII format – How to represent other data types? • Susceptible to misuse (Spamming, faking sender address)
  • 14.