0% found this document useful (0 votes)
8 views

Lecture01 Introduction to TCP-IP Stack Layers

Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Lecture01 Introduction to TCP-IP Stack Layers

Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 42

CENG530

Chapter 02
Introduction to
TCP/IP Stack Layers
Shawqi Kharbash

1
Objectives
• Understand the concept of protocol layering
• Introduce the five layers of the TCP/IP protocol
suite
– How packets in each of the five layers are named.
– Discuss the addressing mechanism used in each
layer.

• Introduce of the OSI model

2
Introduction
A network is a combination of hardware and software that
sends data from one location to another.
• The hardware consists of the physical equipment that
carries signals from one point of the network to another.
• The software consists of instruction sets that make
possible the services that we expect from a network.
Rule 1
Rule 1
Rule 2 Protocol Protocol Rule 2

Rule N
Rule N

Medium
Sender Receiver

3
Protocol Layering
• In data communication and networking, a protocol
defines the rules that both the sender and receiver and
all intermediate devices need to follow to be able to
communicate effectively.
• When communication is simple, we may need only one
simple protocol; when the communication is complex,
we may need to divide the task between different layers,
in which case we need a protocol at each layer, or
protocol layering.

4
A Single-Layer Protocol

Maria and Ann know that they should greet each other when
they meet

Maria and Ann should confine their vocabulary to the level of


their friendship.

Each party knows that she should refrain from speaking when
the other party is speaking.

Each party knows that the conversation should be a dialog, not


a monolog

Maria and Ann should exchange some nice words when they
leave.

5
A Three-Layer Protocol

Two principles of protocol layering:


1. The first principle dictates that if we want bidirectional
communication, we need to make each layer so that it

is able to perform two opposite tasks, one in each


direction.
6
A Three-Layer Protocol

Two principles of protocol layering:


2. The second principle that we need to follow in protocol

layering is that the two objects under each layer at


both sites should be identical.
7
Logical Connections

There is a logical (imaginary) connection at each layer


through which they can send the object created from
that layer.

8
TCP/IP Protocol Suite
• TCP/IP (Transmission Control Protocol/Internet
Protocol) is a hierarchical protocol made up of interactive
modules, each of which provides a specific functionality.
The term hierarchical means that each upper level
protocol is supported by the services provided by one or
more lower level protocols.
• The original TCP/IP protocol suite was defined as four
software layers built upon the hardware. Today, however,
TCP/IP is thought of as a five-layer model.

9
Layers in the TCP/IP Protocol Suite

10
Communication through an Internet

Computer A communicates with Computer B

11
Communication through an Internet

we have five communicating devices in this communication: source


host (computer A), the link-layer switch in link 1, the router, the link-
layer switch in link 2,and the destination host (computer B).

12
Communication through an Internet

Each device is involved with a set of layers depending on the role of


the device in the internet.

13
Communication through an Internet

The two hosts are involved in all five layers; the source host needs to create a
message in the application layer and send it down the layers so that it is
physically sent to the destination host. The destination host needs to receive
the communication at the physical layer and then deliver it through the other
layers to the application layer.

14
Communication through an Internet

The router is involved in only three layers; there is no transport or


application layer in a router as long as the router is used only for
routing.

15
Communication through an Internet

A link-layer switch in a link, however, is involved only in two layers,


data-link and physical.

16
Layers in the TCP/IP Protocol Suite

• The duty of the application, transport, and network layers is


end-to-end.
• The duty of the data-link and physical layers is hop-to-hop,
in which a hop is a host or router.
The domain of duty of the top three layers is the internet,
and the domain of duty of the two lower layers is the link.
17
Identical objects in the TCP/IP
protocol suite

Identical objects below each layer related to each device(second


principle discussed previously for protocol layering).

18
Description of Each Layer:
Physical Layer
• The physical layer is responsible for carrying individual
bits in a frame across the link.
• The physical layer is the lowest level in the TCP/IP
protocol suite, but the communication in the physical
layer still logical.
• There is another, hidden layer, the transmission media,
under the physical layer. Two devices are connected by
a transmission medium (cable or air). The transmission
medium does not carry bits; it carries electrical or optical
signals.

19
Description of Each Layer:
Physical Layer Duties
• The physical layer is concerned with the following:
– Physical characteristics of interfaces and medium.
– Representation of bits.
– Data rate.
– Synchronization of bits.
– Line configuration.
– Physical topology.
– Transmission mode.

20
Description of Each Layer:
Data-link Layer
• The data-link layer is responsible for taking the datagram
and moving it across the link.
• The link can be a wired LAN with a link-layer switch, a
wireless LAN, a wired WAN, or a wireless WAN.
• The data-link layer takes a datagram and encapsulates it in
a packet called a frame.
• TCP/IP does not define any specific protocol for the data-
link layer.
• Each link-layer protocol may provide a different service.
Some link-layer protocols provide complete error detection
and correction, some provide only error correction.

21
Description of Each Layer:
Data-link Layer Duties
• The responsibilities of the data link layer include
the following:
– Framing
– Physical addressing.
– Flow control
– Error control.
– Access control.

22
Description of Each Layer:
Network Layer
• The network layer is responsible for creating a
connection between the source computer and the
destination computer.
• The network layer is responsible for host-to-host
communication and routing the packet through possible
routes.
• The network layer in the Internet includes the main
protocol, Internet Protocol (IP)
– IP defines the format of the packet, called a datagram at this layer
– IP defines the format and the structure of addresses used in this
layer
– IP is responsible for routing a packet from its source to its
destination

23
Description of Each Layer:
Network Layer
• IP is a connectionless protocol that provides no flow control,
no error control, and no congestion control services.
• The network layer also includes unicast (one-to-one) and
multicast (one-to-many) routing protocols. A routing protocol
does not take part in routing (it is the responsibility of IP),
but it creates forwarding tables for routers to help them in
the routing process.

24
Description of Each Layer:
Network Layer
• The network layer also has some auxiliary protocols that
help IP in its delivery and routing tasks.
– The Internet Control Message Protocol (ICMP) : helps IP to
report some problems when routing a packet.
– The Internet Group Management Protocol (IGMP): helps IP in
multitasking.
– The Dynamic Host Configuration Protocol (DHCP): helps IP to
get the network-layer address for a host.
– The Address Resolution Protocol (ARP): helps IP to find the link-
layer address of a host or a router when its network-layer
address is given.

25
Description of Each Layer:
Network Layer Duties
• The responsibilities of the network layer include
the following:
– Logical addressing.
– Routing.
– Fragmenting.
– Packetizing

26
Description of Each Layer:
Transport Layer
• The transport layer is responsible for giving services to the
application layer: to get a message from an application
program running on the source host and deliver it to the
corresponding application program on the destination host.
• The transport layer at the source host gets the message
from the application layer, encapsulates it in a transport
layer packet (called a segment or a user datagram in
different protocols) and sends it, through the logical
connection, to the transport layer at the destination host.
• The logical connection at the transport layer is also end-to-
end

27
Description of Each Layer:
Transport Layer
• There are a few transport-layer protocols in the Internet,
each designed for some specific task, e.g. TCP and UDP.
• The main protocol, Transmission Control Protocol
(TCP), is a connection-oriented protocol that:
– establishes a logical connection between transport layers at two
hosts before transferring data.
– provides flow control (matching the sending data rate of the
source host with the receiving data rate of the destination host to
prevent overwhelming the destination), error control (to guarantee
that the segments arrive at the destination without error and
resending the corrupted ones), and congestion control to reduce
the loss of segments due to congestion in the network.

28
Description of Each Layer:
Transport Layer
• An other common protocol, User Datagram Protocol
(UDP), is a connectionless protocol that transmits user
datagrams without first creating a logical connection.
– In UDP, each user datagram is an independent entity without
being related to the previous or the next one (the meaning of the
term connectionless).
– UDP is a simple protocol that does not provide flow, error, or
congestion control. That means UDP has small overhead.
– UDP is attractive choice to an application program that needs to
send short messages and cannot afford the retransmission.

29
Description of Each Layer:
Transport Layer Duties
• The responsibilities of the transport layer include
the following:
– Service-point addressing.
– Segmentation and reassembly.
– Connection control.
– Flow control.
– Error control.

30
Description of Each Layer:
Application Layer
• Application layer is the highest level in the TCP/IP protocol
suite and the logical connection between the two
application layers is end-to-end.
• Communication at the application layer is between two
processes. Process-to-process communication is the duty
of the application layer.
• The application layer in the Internet includes many
predefined protocols such as:
– The Hypertext Transfer Protocol (HTTP), Simple Mail Transfer
Protocol (SMTP), File Transfer Protocol (FTP), Secure Shell (SSH),
Simple Network Management Protocol (SNMP), Domain Name
System (DNS), ....

31
Encapsulation and Decapsulation

Encapsulation at Decapsulation and Encapsulation Decapsulation at the


the Source Host at the Router Destination Host

32
Addressing

Any communication that involves two parties needs two addresses: source
address and destination address.
We have only four because the physical layer does not need addresses.

33
Addressing: Physical Addresses
• The physical address, also known as the link address, is
the address of a node as defined by its LAN or WAN. It is
included in the frame used by the data link layer. It is the
lowest-level address.
• The physical addresses have authority over the network
(LAN or WAN). The size and format of these addresses
vary depending on the network.
• For example, Ethernet uses a 6-byte (48-bit) physical
address that is imprinted on the network interface card
(NIC).

34
Addressing: Logical Addresses
• Physical addresses are not adequate in an internetwork
environment where different networks can have different
address formats.
• A universal addressing system is needed in which each
host can be identified uniquely, regardless of the
underlying physical network.
• The logical addresses are designed for this purpose.
• A logical address in the Internet is currently a 32-bit
address that can uniquely define a host connected to the
Internet. No two publicly addressed and visible hosts on
the Internet can have the same IP address.

35
Addressing: Port Addresses
• The IP address and the physical address are necessary
for a quantity of data to travel from a source to the
destination host.
• However, arrival at the destination host is not the final
objective of data communications on the Internet.
• The end objective of Internet communication is a
process communicating with another process.
• Computers are devices that can run multiple processes
at the same time, so we need a method to label the
different processes to distinguish between different
processes’ datagrams.
• The port addresses are designed for this purpose.
• A port address in TCP/IP suite is 16 bits in length.

36
Addressing: Name
• Some applications have user-friendly addresses that are
designed for that specific address.
• Examples include the e-mail address (for example,
[email protected]) and the Universal Resource Locator
(URL) (for example, www.uaeu.ac.ae).

37
The OSI Model
• Established in 1947, the International Organization for
Standardization (ISO) is a multinational body dedicated
to worldwide agreement on international standards.
• An ISO standard that covers all aspects of network
communications is the Open Systems Interconnection
(OSI) model. It was first introduced in the late 1970s.
• The purpose of the OSI model is to show how to
facilitate communication between different systems
without requiring changes to the logic of the underlying
hardware and software.
• The OSI model is not a protocol; it is a model for
understanding and designing a network architecture that
is flexible, robust, and interoperable.

38
OSI versus TCP/IP

39
Lack of OSI Model’s Success
• OSI was completed when TCP/IP was fully in place and
a lot of time and money had been spent on the suite;
changing it would cost a lot.
• Some layers in the OSI model were never fully defined.
• When OSI was implemented by an organization in a
different application, it did not show a high enough level
of performance to entice the Internet authority to switch
from the TCP/IP protocol suite to the OSI model.

40
Summary
We have discussed today
– Protocol Layering
– TCP/IP Protocol Suite
– Addressing
– The OSI Model

41
Extra
• OSI Model Explained | Real World Example
https://www.youtube.com/watch?v=LANW3m7UgWs

• TCP/IP Model Explained


https://www.youtube.com/watch?v=OTwp3xtd4dg

Lecture 10 42

You might also like