Open Systems Interconnection (OSI) model


The Open Systems Interconnection (OSI) model has seven layers. The layers are stacked this way.
  1. Physical
  2. Data Link
  3. Network
  4. Transport
  5. Session
  6. Presentation
  7. Application

PHYSICAL LAYER

The Physical layer, the lowest layer of the OSI model, is concerned with the transmission and reception of the unstructured raw bit stream over a physical medium. It defines the type of signal, i.e. electrical, optical or radio waves.


DATA LINK LAYER

The data link layer provides error-free transfer of data frames from one node to another over the physical layer. Following are functions of the data link layer:
  • Physical addressing:- Adds source and destination layer 2 (MAC address on Ethernet) to header of frame.
  • Frame error detection:- Adds a Frame Check Sequence (FRC) or Cyclic Redundancy Check (CRC) to the trailer of the frame, which drops the frame if the value differs at source and destination.
Header Information:
  • Source and destination MAC address
Trailer Information:
  • Frame Check Sequence (FRC)

NETWORK LAYER

This layer provides routing technologies, creating logical paths, known as virtual circuits for transmitting data from node do node. It provides:

  • Source to destination delivery: transfers packets from source to destination.
  • Logical addressing: adds the source and destination IP address to the header.
  • Routing: selects the optimal path out of multiple paths that can be followed by packets.
  • Inter-networking: connects two or more different subnets.
Header Information:
  • Source and destination IP address
  • Time-to-Live (TTL): it specifies how long a packet is allowed to travel through the internet. Each router decrements the value of this field by one before forwarding it. When it's value reaches to 0, the packet is discarded by the router.
Protocols: IP, IPX, routing protocols (RIP, EIGRP, OSPF, BGP etc), ARP, ICMP.


TRANSPORT LAYER

The transport layer ensures that messages are delivered error-free, in sequence, and with no losses or duplicates. This layer provides:

  • Service point addressing: This layer includes port address in the header, using which, the transport layer delivers the message to the correct process at destination.
  • Flow control: Transport layer assures that the sending of the data depends upon the receiving capacity of the receiver.
  • Error control: ensures that the the entire message is delivered at destination machine without any error. Segments are re-transmitted to achieve error correction.
  • Segmentation and reassembly: splits the message into smaller units (if not already small enough), and assigns a sequence number to these segments. The transport layer at the destination station reassembles the message.
Header Information:
  • Source and destination port number.
  • TCP sequence number.
  • Acknowledgement number.
  • TCP length: the length of the TCP header and data.
Protocols: TCP, UDP, SCTP


SESSION LAYER

Session layer establishes, maintains and terminates the connections between end-user application process. Session-layer services are commonly used in application environments that make use of remote procedure calls (RPCs). It provides the following services:

  • Authentication
  • Authorization
  • Session restoration (checkpointing and recovery): At this layer, each session is divided into sub-sessions by inserting checkpoints into the stream. These checkpoints allows information of different streams, perhaps originating from different sources, to be properly combined or synchronized. It also ensure that the session can be backtracked in case of errors.
Header Information: 
Information about the checkpoints.

Protocols: PPTP, L2TP, RPC, PAP


PRESENTATION LAYER

The presentation layer formats the data to be presented to the application layer. The data is encoded or translated to different formats such as .avi, .doc, .jpg and so on, so that the application layer program can recognize and work with it. The presentation layer provides:
  • Character code translation: for example, ASCII to EBCDIC.
  • Data compression: reduces the number of bits that need to be transmitted on the network.
  • Data encryption: encrypt data for security purposes. For example, password encryption.
Examples: File format converters, Winzip, Winrar, GPG


APPLICATION LAYER

This layer provides an interface for the user to access the information on a network.

Protocols: HTTP, FTP, SMTP, POP3, NTP, TFTP, Telnet, DNS, SNMP





Related links:
http://support.microsoft.com/kb/103884
http://en.wikipedia.org/wiki/OSI_model




Comments

Popular posts from this blog

Specifying SSH port in Ansible Inventory

Ansible-Playbook to display output of multiple show commands (using stdout_lines with Loop)

Filtering Routes in BGP using Route-maps and Prefix-list

Ansible Playbook for Network OS Upgrade with pre and post checks

VMware NSX Traffic Flow — East-West & North-South

Bypassing Proxy Server in Google Chrome

Export or Backup Azure Network Security Groups into CSV using PowerShell

Ansible-playbook for backing up running config of Cisco IOS