Professional Documents
Culture Documents
CN UNIT-III
CN UNIT-III
CN UNIT-III
SYLLABUS:
Transport Layer: Introduction and Transport-Layer Services,
Multiplexing and De-multiplexing, Connectionless Transport: UDP,
Principles of Reliable Data transfer, Connection-Oriented Transport:
TCP, Principles of Congestion Control, TCP Congestion Control
Introduction:
It Is the 4TH Layer in OSI Reference Model
The Transport Layer is regarded as the highest of the
lower layer protocols in the OSI protocol stack.
The Transport layer provides the means to establish, maintain,
and release transport connections on behalf of session entities.
It provides reliable end-to-end data transport.
The transport layer protocols are implemented in the end
systems but not in the network routers.
A computer network provides more than one protocol to the
network applications. For example, TCP and UDP are two
transport layer protocols that provide a different set of services
to the network layer.
All transport layer protocols provide multiplexing/DE
multiplexing service. It also provides other services such as
reliable data transfer, bandwidth guarantees, and delay
guarantees.
o End-to-end delivery
o Addressing
o Reliable delivery
o Flow control
o Multiplexing
End-to-end delivery:
Addressing:
Reliable delivery:
o Error control
o Sequence control
o Loss control
o Duplication control
Error Control
Sequence Control
Loss Control
Flow Control:
UDP Header:
UDP header is as simple as its function.
Source Port (16-bits) - It identifies source port of the application
process on the sending device.
Destination Port (16-bits) - It identifies destination port of the
application process on the receiving device.
Sequence Number (32-bits) - Sequence number of data bytes of a
segment in a session.
Acknowledgement Number (32-bits) - When ACK flag is set, this
number contains the next sequence number of the data byte expected
and works as acknowledgement of the previous data received.
Data Offset (4-bits) - This field implies both, the size of TCP header (32-
bit words)
Reserved (3-bits) - Reserved for future use and all are set zero by
default.
Flags (1-bit each)
Windows Size - This field is used for flow control between two stations
and indicates the amount of buffer (in bytes) the receiver has allocated
for a segment, i.e. how much data is the receiver expecting.
Checksum - This field contains the checksum of Header, Data and
Pseudo Headers.
Urgent Pointer - It points to the urgent data byte if URG flag is set to 1.
Options - It facilitates additional options which are not covered by the
regular header. Option field is always described in 32-bit words
Differences between TCP & UDP:
BASIS FOR COMPARISON
TCP UDP
Meaning TCP establishes UDP sends the data directly
connection between to the destination computer
the computers without checking whether
before transmitting the system is ready to
the data receive or not
Expands to Transmission User Datagram Protocol
Control Protocol
Connection Type Connection Oriented Connection Less
BASIS FOR COMPARISON
TCP UDP
Speed Slow Fast
Reliability Highly Reliable Unreliable
Header Size 20 Bytes 8 Bytes
Acknowledgement It takes It neither takes
acknowledgement of acknowledgement nor it re
data and has the transmits the lost data.
ability to re transmit,
if the user requests.
(Or)
Differences between TCP/UDP:
TCP UDP
Transmission Control Protocol User Datagram Protocol
Reliable Unreliable
Connection-oriented Connectionless
Segment retransmission and flow No windowing or
control through windowing retransmission
Segment sequencing No sequencing
Acknowledge sequencing No acknowledgment
Slow Fast
Highly Reliable Unreliable
20 Bytes 8 Bytes
1. HTTP
2. FTP
3. Telnet
4. SMTP, POP3
Port Transport
Service name
Number protocol
23 Telnet TCP
50, 51 IPSec
161, 162 Simple Network Management Protocol (SNMP) TCP and UDP
443 HTTP with Secure Sockets Layer (SSL) TCP and UDP
TCP and
3389 Remote Desktop Protocol
UDP
Principles of Reliable Data Transfer:
Transport Layer Protocols are central piece of layered
architectures, these provides the logical communication
between application processes.
These processes uses the logical communication to transfer data
from transport layer to network layer and this transfer of data
should be reliable and secure.
The data is transferred in the form of packets but the problem
occurs in reliable transfer of data.
For example, TCP (Transmission Control Protocol) is a reliable data
transfer protocol that is implemented on top of an unreliable layer, i.e.,
Internet Protocol (IP) is an end to end network layer protocol.
M*s=C+ρ*s
where
S – is time taken
M – Maximum output rate
ρ – Token arrival rate
C – Capacity of the token bucket in byte
Let’s understand with an Example,