TCP/IP Model
TCP/IP MODEL
What is a protocol?
• A protocol is a collection of rules and procedures for two
computers to exchange information
• Protocol also defines the format of data that is being
exchanged
2
IP Characteristics
• IP is a connectionless protocol
– No concept of a job or a session (each packet is treated as
an entity in itself)
• IP is an unreliable protocol
– It is unconcerned with whether a packet reaches its
eventual destination, or whether they arrive in the original
order
– IP cannot tell if packets were lost or whether they were
received out of order
• IP packets are not identified as a part of a sequence or
belonging to a particular job.
IP Packet Header
Version Header length Service type Total length
Identification Flags Fragment Offset
Time to live Protocol Header checksum
Source address
Destination address
IP Options Padding
What is TCP/IP?
• TCP/IP is a set of protocols developed to allow cooperating
computers to share resources across a network
• TCP stands for “Transmission Control Protocol”
• IP stands for “Internet Protocol”
• They are Transport layer and Network layer protocols respectively
of the protocol suite
• The most well known network that adopted TCP/IP is Internet –
the biggest WAN in the world
• Because TCP/IP was developed earlier than the OSI 7-layer mode,
it does not have 7 layers but only 4 layers
5
TCP and UDP
TCP – Transmission Control Protocol
• TCP is a connection-oriented protocol
• Does not mean it has a physical connection between sender
and receiver
• TCP provides the function to allow a connection virtually
exists – also called virtual circuit
• TCP provides the functions:
• Dividing a chunk of data into segments
• Reassembly segments into the original chunk
• Provide further the functions such as reordering and data
resend
• Offering a reliable byte-stream delivery service 6
TCP/IP Model
OSI & TCP/IP Models
TCP/IP Model
TCP/IP Model
Application Layer
Application programs using the network
Transport Layer (TCP/UDP)
Management of end-to-end message transmission,
error detection and error correction
Network Layer (IP)
Handling of datagrams : routing and congestion
Data Link Layer
Management of cost effective and reliable data delivery,
access to physical networks
Physical Layer
Physical Media
TCP SEGMENT
TCP Packet Header
Source Port Destination Port
Sequence Number
Acknowledgement Number
Header Length Code Bits Window
Checksum Urgent pointer
Options Padding
User Datagram Protocol
• UDP is a simple protocol
• UDP is unreliable and connectionless
– A connection with a host is not necessary before
exchanging data
– No mechanism for ensuring that data sent is received
• Main function is to specify the upper layer
protocols
• Useful for broadcasting since it does not require
a connection
UDP Packet Header
Source Port Destination Port
Message length Checksum
•Two different application one using UDP and another using TCP may use the
same port number. The two data streams are distinguished by the protocol
field in the IP address header
•The checksum is optional.