Professional Documents
Culture Documents
lo
transport protocols run in end data link
icg
physical
systems
al
network
en
data link
d
send side: breaks app
-e
physical network
nd
data link
messages into segments, physical
tr
a
passes to network layer network
ns
data link
po
physical
rt
rcv side: reassembles
segments into messages, application
transport
passes to app layer network
data link
more than one transport physical
lo
data link
g
flow control
ic
physical
al
network
en
connection setup data link
d
-e
physical network
nd
data link
unreliable, unordered physical
tr
a
delivery: UDP
network
ns
data link
po
physical
rt
no-frills extension of
“best-effort” IP application
transport
network
services not available: data link
physical
delay guarantees
bandwidth guarantees
P3 P1
P1 P2 P4 application
application application
host 2 host 3
host 1
Transport Layer 3-6
How demultiplexing works
host receives IP datagrams
each datagram has source IP address,
destination IP address 32 bits
each datagram carries 1 transport-
layer segment source port # dest port #
each segment has source, destination
port number
(recall: well-known port numbers for other header fields
specific applications)
host uses IP addresses & port numbers to
direct segment to appropriate socket
application
data
(message)
P2 P1
P1
P3
P1 P4 P5 P6 P2 P1P3
SP: 5775
DP: 80
S-IP: B
D-IP:C
P1 P4 P2 P1P3
SP: 5775
DP: 80
S-IP: B
D-IP:C
Sender: Receiver:
treat segment contents as compute checksum of received
sequence of 16-bit segment
integers check if computed checksum
checksum: addition (1’s equals checksum field value:
complement sum) of NO - error detected
1 1 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0
1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
wraparound 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1 1
sum 1 1 0 1 1 1 0 1 1 1 0 1 1 1 1 0 0
checksum 1 0 1 0 0 0 1 0 0 0 1 0 0 0 0 1 1
Transport Layer 3-16