Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
The 7 layers of the osi model
1. The 7 Layers of the OSI Model
The OSI, or Open System Interconnection, model defines a
networking framework for implementing protocols in seven layers.
Control is passed from one layer to the next, starting at the
application layer in one station, proceeding to the bottom layer,
over the channel to the next station and back up the hierarchy.
The OSI, or Open System Interconnection, model defines a networking
framework for implementing protocols in seven layers. Control is passed from
one layer to the next, starting at the application layer in one station, proceeding
to the bottom layer, over the channel to the next station and back up the
hierarchy.
1
2. This layer supports application and end-user processes.
Communication partners are identified, quality of service is identified,
user authentication and privacy are considered, and any constraints
on data syntax are identified. Everything at this layer is application-
Application
specific. This layer provides application services for file transfers, e-
(Layer 7)
mail, and other network software services. Telnet and FTP are
applications that exist entirely in the application level. Tiered
application architectures are part of this layer.
This layer provides independence from differences in data
representation (e.g., encryption) by translating from application to
network format, and vice versa. The presentation layer works to
Presentation transform data into the form that the application layer can accept.
(Layer 6) This layer formats and encrypts data to be sent across a network,
providing freedom from compatibility problems. It is sometimes
called the syntax layer.
This layer establishes, manages and terminates connections
between applications. The session layer sets up, coordinates, and
Session terminates conversations, exchanges, and dialogues between the
(Layer 5) applications at each end. It deals with session and connection
coordination.
This layer provides transparent transfer of data between end
Transport systems, or hosts, and is responsible for end-to-end error recovery
(Layer 4) and flow control. It ensures complete data transfer.
This layer provides switching and routing technologies, creating
logical paths, known as virtual circuits, for transmitting data from
Network node to node. Routing and forwarding are functions of this layer, as
(Layer 3) well as addressing, internetworking, error handling, congestion
control and packet sequencing.
At this layer, data packets are encoded and decoded into bits. It
furnishes transmission protocol knowledge and management and
handles errors in the physical layer, flow control and frame
synchronization. The data link layer is divided into two sub layers:
Data Link The Media Access Control (MAC) layer and the Logical Link Control
(Layer 2) (LLC) layer. The MAC sub layer controls how a computer on the
network gains access to the data and permission to transmit it. The
LLC layer controls frame synchronization, flow control and error
checking.
This layer conveys the bit stream - electrical impulse, light or radio
signal -- through the network at the electrical and mechanical level. It
provides the hardware means of sending and receiving data on a
2
3. The TCP/IP protocol stack
The TCP/IP protocols enable communication between pairs of hosts, or ``peers'', on a
network. The TCP/IP protocol structure can be conceptualized as a series of layers, or
``stack'', between an application and the network. Each protocol layer on one peer has a
corresponding layer on the other peer. To the application, it appears that it has a virtual
connection to an application running on another host. In reality, data is passed over the
network in the physical form that the network can handle. Each layer is required, by
design, to handle communications in a predetermined fashion. Each protocol formats
communicated data and appends information to or removes information from the data.
Then the protocol passes the data to a lower layer on the sending host or a higher layer on
the receiving host, as illustrated in ``Sender/receiver interaction''.
`
Sender/receiver interaction
The interface between the application and the transport layers is termed a transport
interface. Interfaces such as sockets and TLI/XTI eliminate the need for applications to
know about the transport layer in detail. For more information about the programming
interfaces to the transport layer, see Using network programming interfaces.
``Encapsulation/decapsulation of application data within a network stack'' shows how
each layer adds (or removes) header information to data traveling away from (or toward)
the application layer. The process of adding header information is termed
``encapsulation''; removing header information is termed ``decapsulation'' or
``unencapsulation''.
3
4. Encapsulation/decapsulation of application data within a network stack
Networking application programs send messages or streams of data to one of the Internet
transport Layer protocols, either the User Datagram Protocol (UDP) or the Transmission
Control Protocol (TCP). These protocols receive the data from the application, divide it
into smaller pieces called TCPsegments or UDP packets, add a destination address, and
then pass the packets down to the next protocol layer, the network layer.
The network layer encloses the packet in an Internet Protocol (IP) datagram, adds the
datagram header, decides where to send the datagram (either directly to the destination
system or indirectly via a router or gateway), and passes the datagram down to the data
link layer.
The data link layer accepts IP datagrams, encapsulates them within frames that are
specific to the network hardware such as Ethernet, Token-Ring or Fiber Distributed Data
Interface (FDDI), and transmits these over the network.
Frames received by a host are processed through the protocol layers in the reverse order.
Each layer strips off the corresponding header information, until the data ends up at the
application layer. Frames are received by the data link layer which strips off the frame
header and trailer, and sends the datagram up to the network layer. The network layer
strips off the IP header and sends the packet up to the transport layer. The transport layer
strips off the TCP or UDP header and sends the data up to the application.
As hosts on a network can send and receive information simultaneously, data may be
traveling both up and down the layers of the networking stack at the same time.
4
5. ``Networking stack support for the TCP/IP protocols'' illustrates the relationships
between the various protocols that are supported within the stack.
Networking stack support for the TCP/IP protocols
This arrangement is termed a ``dual-stack'' as both IPv4 and IPv6 are supported; the path
that data takes is determined by the IP header on incoming datagrams or by the IP address
format used by applications in outgoing datagrams.
NOTE: In UnixWare 7 Release 7.2, the TCP/IP networking stack is implemented using
``memory buffers'' or ``mbufs'' as in BSD networking, rather than using STREAMS as
was usual in SVR4-based systems. This does not prevent the conceptualization of the
networking stack as a series of layers.
The following sections provide an overview of how each protocol layer handles
messages:
• ``Application layer''
• ``Transport layer''
• ``Network layer''
• ``Data link layer''
• ``Physical layer''
5
6. Networking stack support for the TCP/IP protocols
This arrangement is termed a ``dual-stack'' as both IPv4 and IPv6 are supported; the path
that data takes is determined by the IP header on incoming datagrams or by the IP address
format used by applications in outgoing datagram
•
MAC Layer
The Media Access Control Layer is one of two sublayers that make up the Data Link
Layer of the OSI model. The MAC layer is responsible for moving data packets to and
from one Network Interface Card (NIC) to another across a shared channel.
See a breakdown of the seven OSI layers in the Quick Reference section of Webopedia.
The MAC sublayer uses MAC protocols to ensure that signals sent from different stations
across the same channel don't collide.
6
7. Different protocols are used for different shared networks, such as Ethernets, Token
Rings, Token Buses, and WANs.
Also see "The OSI Reference Model - Understanding Layers" in Webopedia's "Did You
Know..." section.
Telnet
The Telnet protocol enables terminals and terminal-oriented processes to communicate
on a network running TCP/IP. It is implemented as the program telnet(1tcp) on the local
machine and the daemon telnetd(1Mtcp) on the remote machine. telnet provides a user
interface through which two hosts can open communications with each other, then send
information on a character-by-character or line-by-line basis.
telnet includes a set of internal commands that allow fine control over its operation.
The telnetd daemon on the remote host handles requests from the telnet command.
FTP
The File Transfer Protocol (FTP) transfers files to and from a remote network. The
protocol includes the ftp(1tcp) command on the local machine and the ftpd(1Mtcp)
daemon on the remote machine. ftp lets you specify on the command line the host with
whom you want to initiate file transfer and options for transferring the file. The ftpd
daemon on the remote host handles the requests from your ftp command.
ftp includes a set of internal commands that allow fine control over its operation.
The procedure for setting up an anonymous FTP server may be found in ``Configuring
File Transfer Protocol (FTP) servers''.
7