Академический Документы
Профессиональный Документы
Культура Документы
pp
o Web
W b Browsing
B
i (HTTP)
o File Transfer Protocol (FTP)
o Electronic
El t ni M
Mail
il (SMTP)
o Domain Name Service (DNS)
o VoIP,
VoIP Internet Telephony
o Peer-to-peer Services
(This set of slides are mainly from the lecture notes of Prof. S. K. Bose)
Network
query/request
response/reply
(speaks first)
typically requests service from
s
server,
Web: client implemented in
browser; e-mail: in mail reader
application
transport
network
data link
physical
Server:
provides requested service to client
e.g., Web server sends requested Web
request
reply
l
application
transport
network
data link
l
physical
Addressing Processes
Identifier used to uniquely identify processes (both sending or
receiving) is
< IP Address, Port Number >
will
ill always
l
s be
b available
il bl att the
th specified
sp ifi d well
ll kn
known
n p
portt number
numb
Bandwidth
some apps (e.g., multimedia)
require minimum amount of
bandwidth to be effective
other apps (elastic apps)
make use of whatever
bandwidth they
y get
g
Internet Transport
p
Protocol Services
TCP service
Transmission Control Protocol
(Connection-Oriented Stream
Service)
UDP service
Universal Datagram Protocol
(Best-Effort, Connection-Less
Datagram Service)
TCP service behaves like a virtual data pipe! Whatever you push in (by
writing to the corresponding TCP socket) at one end of the pipe
eventually comes out,
out in sequence,
sequence from the other end of the pipe (on
the corresponding socket) !
UDP is more uncertain. Whatever data you give to UDP must be given as
packet and UDP will try
y its best to deliver it at the other end. It
a p
does not give any guarantees on this or even that it will deliver the data
packets in sequence.
Internet Transport
p
Protocols Services
TCP service:
connection-oriented: setup
UDP service:
unreliable data transfer
between sending and
receiving processes
does not provide:
connection setup,
reliability, flow control,
l timing,
congestion control,
or bandwidth guarantee
Application must
m st first set-up
set p a
TCP connection and then use
it.
The connection must also be
terminated after use
file
file,
Web page consists of base HTML-file which includes several
referenced objects
Each object is addressable by a URL
Example URL:
http://www.iitg.ernet.in/ece/fac.htm
p
g
host name
path name
where to find the object in the given host
Try View Source in IE to see the HTML file for a web page. Note that this is
y a text file with links/URLs for all the objects
j
reference byy the web p
page
g
always
PC running
Explorer
Server
running
Web
Server program like
Apache
Mac running
Navigator
HTTP Overview
Uses TCP as follows client initiates TCP
may be
b
inconsistent, must be
reconciled
HTTP connections
Non-persistent HTTP
Persistent HTTP
Types
yp of HTTP Connections
Non persistent
Non-persistent
Persistent
P
i t t
without
Pipelining
p
g
Persistent
P
sist t with
ith
Pipelining
Authorization
client
server
Cookies:
Cookies:
Advantages
g and Controversies
Cookie Controversies
Using
g a HTTP Proxy
y (Proxy
(
y Server))
Client 1
Server A
Proxy
Server
Server B
Client N
Local Network
Domain
Internet
Using
g a HTTP Proxy
y (Proxy
(
y Server))
Client makes all its HTTP requests to its Proxy Server
Proxy Server gets the response (requested file etc.)
etc ) from the
corresponding server and forwards it to the requesting client
In
I case requested
t d fil
file iis
already in the Proxys cache, then Client 1
it can forward the cached copy
to the Client
Internet Hosts only see the
Proxy Server and cannot see the
individual clients. Proxy
y also
serves as a security barrier (e.g.
a firewall) to protect the clients
from the Internet
Server A
Proxy
Server
Server B
Client N
Simpler
p
file transfer method which does not
have all the functionalities of FTP
NFS Network
NFS:
N t
k File
Fil System
S t
user
at host
FTP
FTP
user
client
interface
f l transfer
file
f
llocall fil
file
system
FTP
server
remote file
system
remote)
server: remote host
ftp: may be between two programs or with a human user
on the client side
f
ftp
p server: port
p
21 (well
(
known p
port))
Control
Process
Server System
Control
Process
Data
Transfer
Operating System
Operating System
TCP/IP
Internet
Servver Data
Connection
Data
Transfer
Server Co
ontrol
Connecttion
Client Data
Conn
nection
Client System
Client Co
ontrol
Connec
ction
Schematic Representation
p
of FTP
and stays
y for the whole session; Client establishes connection
with port 21 on the Server side; FTP Server is always
listening at port 21 for Clients who want to set up FTP
connections with it
Client uses the Control Connection to do commands like
or
FTP
client
FTP
server
Electronic Mail
outgoing
message queue
user mailbox
user
agent
mail
server
SMTP
SMTP
User Agent
SMTP
mail reader
for composing, editing and
user
agent
SMTP
mail
server
user
agent
user
agent
mail
server
user
agent
user
agent
Electronic Mail
Mail Servers
mailbox contains incoming
user
agent
mail
server
user
agent
SMTP
SMTP
SMTP
mail
server
user
agent
user
agent
mail
server
user
agent
user
agent
to server,
server port 25
handshaking (greeting)
transfer of messages
closure
command/response interaction
pp
non-ASCII contents described later)
support
SMTP
P modified
d f d to provide
d some additional
dd
l security f
features
as well (these dont work too well, spamming and viruses still
get spread)
SMTP: Comparisons
p
with HTTP
SMTP p
persistent like persistent
p
HTTP/1.0
HTTP: pull (client picks up content from web server)
SMTP: push (client pushes content to other server)
Both HTTP and SMTP have ASCII command/response
Mail Message
g Format
Standard Format for Text
Message:
header
To:
From:
Subject:
Subject
body
blank
line
Mail Message
g Format with Multimedia Extensions
MIME: multimedia mail extension, RFC 2045, 2056
additional lines in msg header declare MIME content
type
MIME version
method used
to encode data
multimedia data
type,
yp , subtype,
yp ,
parameter declaration
encoded data
From: alice@crepes.fr
To: bob@hamburger.edu
Subject: Picture of yummy crepe.
MIME-Version:
MIME
Version: 1.0
Content-Transfer-Encoding: base64
Content-Type: image/jpeg
base64
b
64 encoded
d d d
data
t .....
.........................
......base64 encoded data
MIME types
html
Image
gif
Audio
Video
quicktime
Application
other data that must be
processed by reader
before viewable
example
p subtypes:
yp
msword, octet-stream
Alice
SMTP
user
agent
Bob
senders mail
server
receivers mail
server
Alice logs
logs into her mail server to write mail for Bob
Bob.
(Use mail, elm, pine etc. for this.)
their
th
i respective
ti User
U
Agents
A
t to
t write
it and
d read/handle
d/h dl th
the
mail
The User Agents
g
interact with the corresponding
p
g mail
1.
Bobs mail server can be down when Alice writes her mail,
2.
Alice and Bob can handle multimedia mail and do not have to
be restricted to the boring
boring text mail of early days
3.
Alice and Bob can choose to keep their mail in their own
computers and not on the mail server
SMTP
SMTP
senders mail
server
Mail
Access
P t
Protocol
l
user
agent
receivers mail
server
Solution:
Bob runs a Mail
Access Protocol
to get/read the
mail from his
server
SMTP
SMTP
senders mail
server
Mail
Access
Protocol
user
agent
receivers mail
server
Some Mail Access Protocols that Bob can typically run are
1. POP3
2. IMAP
3. HTTP
P
Using Web
b Browsers
B
and
d Web-based
b b
dE
Emaill
(like Hotmail, Yahoo etc.) to read/write mail
directly at the mail server
POP3 Protocol
3. Update:
POP3 Options
p
Two options are possible 1. Download-&-Delete
Automatically
u m
y download
w
received m
mails ffrom
m m
mailbox in
server to users own computer and DELETE them from the
server
2 Download
2.
Download-&-Keep
& Keep
POP3 Options
p
New mail
N
il enters the
h default
d f l INBOX folder,
f ld
user can
subsequently create folders and move received mails to
these folders
IMAP keeps
k
user state across sessions:
i
Disadvantage:
Di d
Security
i may be
b a concern
servers
name
pp
host names to IP
DNS services to translate user-supplied
addresses (i.e. resolve names)
The DNS N
Th
Name Space
S
Resource Records
Name Servers
Hierarchical Operation
p
of DNS
User
Application
DNS Query
DNS
User Response
Host
Local
Name
Server
other, hierarchically
organized name servers
on the Internet who can
help answer the query
Hierarchical Operation
p
of DNS
Types of Name Servers
1 L
1.
Locall Name
N
Server
S
2. Root Name Server
3 Authoritative Name Server
3.
4. Intermediate Name Server
No server has
all the name-to-IP
address mappings
Cooperatively,
they can usually
find one who does
have this
Hosts sends DNS query only to its own Local Name Server
Local Name Server may query others to get the required
information if it does not have this itself.
itself Caching is used for greater
efficiency and response speed. Cache is also timed out
(Query used may be Iterative or Recursive)
Iterative
It
ti if a DNS passes queries
i to
t other
th DNS to
t query on its
it behalf.
b h lf
Recursive if it finds higher order DNS and contacts them directly
Hierarchical Operation
p
of DNS
Root
Name
Server
Local
N
Name
Server
Requesting
Host
Target Hosts
Domain
Authoritative
Name Server
Target
g Host for DNS
Query
Each ISP,
ISP company has Local (default) Name Server , i.e.
ie
for its local domain (reachable within only a few routers)
For a Host, the IP address of its Local Name Server is
usually configured in it when the Host is set up.
up
Some times, multiple local name servers may be set up, e.g.
as Primary Name Server and Secondary Name Server.
In some networks, Hosts may be configured to get the
address of the DNS automatically (e.g. from a Domain
Controller))
Hierarchical Operation
p
of DNS
A DNS Query which cannot be answered by the Local Name Server
will be referred up to another,
another hierarchically higher,
higher name server.
server The
Local Name Sever acts as the DNS Client and queries the next higher
DNS that it knows about
A Host in the EEE domain will first ask the EEE DNS.
If the EEE DNS does not know then it will refer the
query to the next higher CITS DNS
Eventually,
E ntu ll an
n unanswered
un ns
d DNS query
qu
will
ill reach
ch a Root
R t Name
N m Server
S
of the Internet
The Internet has a few (about a dozen or so) very large Root Name
Servers. These know more about the Internet mappings than any other
queries will eventually
y be sent to one of
server and all unanswered DNS q
these.