A protocol is basically a set of rules that define how communication will occur. Network protocols define the rules of communication that two networking systems will have to adhere to, in order to exchange information over a network. This is analogous to two people conversing and trying to communicate an idea to each other. Each of the two people involved will need to speak and understand a similar language for the communication to be effective, and the same applies to computers on a network. We take a look at the two most popular network protocols : NetBEUI and TCP/IP
NetBios Extended User Interface is a transport protocol that was originally developed by IBM and then adapted by Microsoft in its windows operating systems. This is a non-routable protocol. A non-routable protocol sends data only within the network (LAN) and cannot bypass the router to send the data to other networks. This protocol is very efficient, easy to implement and works without any overheads in local networks. A unique machine name is the only configuration required for this protocol to work. NetBEUI relies on NetBIOS (Network Basic Input/Output System) for session management functionality. NetBIOS is an API that is used to establish communication with a remote system. The communication modes used by NetBIOS is of two types:-
1. Session Mode : This is basically a connection oriented communication in which NetBIOS is responsible for establishing a proper session with the target machine, monitoring the network session to detect any errors in transmission, and then recovering from those errors and re-transmitting any data that went missing or was corrupt.
2. Datagram Mode : This is a connectionless communication in which a session is not needed. Error Detection and Recovery are not supported in this mode.
NetBIOS uses NetBIOS names for identifying computers on a network. The NetBIOS name for a computer on the network has to be unique.
Transmission Control Protocol/Internet Protocol (TCP/IP) is the most widely used network protocol today. This is a routable protocol and is the basis on which the internet is built. One of the major advantages of TCP/IP protocol is that it can be used to connect dissimilar networks together, and so it has become the protocol of the internet. There are however two major drawbacks of this protocol:-
1. Configuration : TCP/IP requires configuration and familiarity with terms like IP address, Subnet Masks and Default gateways. This results in a bit of a learning curve as compared to NetBEUI.
2. Security : Since TCP/IP is an open protocol, it poses a security threat for data being transmitted through it. Additional components have to be implemented in for the data transmission to be secure. This includes implementation of SSL to protect web based data transmissions.
Routable vs. Non-Routable Protocols
A routable protocol will have a 'Network ID' in its addressing scheme, thereby enabling it to identify 'where' or on which network a machine resides. Hence, data sent using this type of protocol can be delivered to an external network through a Router.
A Non-Routable protocol has only the machine name in its addressing scheme and hence cannot be used to identify 'where' the machine resides. It will have the capability to look up computer names only in the local LAN and data sent with this protocol cannot bypass a router to a different network. The data thus sent will be discarded by the Router.
The OSI Model
The OSI (Open Systems Interconnect) model was defined as a set of standards, by the International Organisation for Standardization (ISO) for manufacturers of networking components, that would basically allow these components to communicate through dissimilar networks. The OSI model is made up of seven layers, with each layer having its own specific function and role in data communication. The layers from top to bottom are - Application, Presentation, Session, Transport, Network, Data Link and Physical. The understanding of the OSI model is critical in understanding, how data transmission is carried out within a network.
This layer on the sending machine is actually responsible for generating the request that requires a network communication. This could be any type of request - For example, a HTTP request to retrieve a web page. So, a user firing up a browser (which is the application) types in a site's address (Request). This is a typical request. Other requests can include access to e-mail through an e-mail client (Outlook) or access to files through FTP.
This layer is mainly responsible for data formatting as required by the receiving system. Once the application layer generates the request, the data is sent down to the presentation layer for formatting. The formatted data will thus be interpreted accordingly at the presentation layer on the receiving machine.
The session layer is responsible for establishing a session between two network systems and basically defines the rules under which the communication will take place. The rules can dictate as to which of the two systems transmits data and when, and how much data can be transmitted at a time. Both systems that are communicating have to agree on the rules. Only then can effective communication take place. The session layer is also responsible for maintaining the session through error detection and control, and also responsible for terminating the session successfully once the communication is complete.
The transport layer handles reliable or unreliable delivery of the data from one network system to another. For reliable protocols, the transport layer works hard to ensure that data being sent is received as intended by the recipient, followed by a proper acknowledgment. A connection oriented communication thus performs what is called a 'handshake' between the two systems to ensure reliable delivery of data. During a handshake, the two systems involved decide the rules of communication, determine transmission speed and which ports to use, and how the session will be finally terminated.
A connectionless communication just transmits the data and does not ensure acknowledgment of the data being delivered. This is faster than the connection oriented communication as there is less overhead involved, but the down side is that there will be no reliability as regards to data delivery.
The network layer is responsible for logical addressing and delivery or routing of data packets, using the information stored in a router table. A router table is a list of available destinations that a specific router has accessed before and stored in its memory. This layer works with logical address that basically hold information which uniquely identifies a system on a network and also the network on which the system resides. An example of a logical address is an IP address that looks something like 192.168.x.x
The network layer also adds the source IP address (the machine from which the request originated) and the destination IP address (intended recipient) to the data packet, so that the recipient knows from which system the request was generated.
Data Link Layer
This layer is responsible for converting the data packets into electrical signals that get transmitted through the network medium. MAC addresses are used here, which basically define the physical address of a machine on the network.
This layer has to do with the physical structure or topology of the network and is concerned with the movement of the electrical signal across the physical medium and related encoding. This is the layer where the sender places data on the wire, and the receiver picks this data off the wire for processing.