0% found this document useful (0 votes)
42 views129 pages

CN Question Bank 24-25

The document is a question bank for a Computer Networks course, detailing various concepts such as definitions, applications, and types of networks including LAN, WAN, and topologies like mesh, star, bus, and ring. It also covers the differences between the internet and intranet, as well as the significance of network hardware and software. Additionally, it discusses social issues related to computer networks and the importance of protocols in network communication.

Uploaded by

indhu mathi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
42 views129 pages

CN Question Bank 24-25

The document is a question bank for a Computer Networks course, detailing various concepts such as definitions, applications, and types of networks including LAN, WAN, and topologies like mesh, star, bus, and ring. It also covers the differences between the internet and intranet, as well as the significance of network hardware and software. Additionally, it discusses social issues related to computer networks and the importance of protocols in network communication.

Uploaded by

indhu mathi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 129

COMPUTER NETWORKS

QUESTION BANK

DEPARTMENT OF COMPUTER SCIENCEAND


ENGINEERING
(2024-2025)
UNIT –I

SHORT QUESTION AND ANSWERS

1) Define Computer Networks .Explain Apllications of CN

Network A network is a set of devices (often referred to as nodes) connected by


communication links. A node can be a computer, printer, or any other device capable of
sending and/or receiving data generated by other nodes on the network.
USES OF COMPUTER NETWORKS

1. Business Applications

a) Resource Sharing:The goal is to make all programs, equipment, and especially data available to
anyone on the network without regard to the physical location of the resource or the user.

Probably even more important than sharing physical resources such as printers, and tape backup systems, is
sharing information. Companies small and large are vitally dependent on computerized information and large
are vitally dependent on computerized information.

Networks called VPNs (Virtual Private Networks) may be used to join the individual networks at different
sites into one extended network.

b) Providing Communication Medium:Every company that has two or more computers now has
email (electronic mail), which employees generally use for a great deal of daily communication.

Telephone calls between employees may be carried by the computer network instead of by the
phone company. This technology is called IP telephony or Voice over IP (VoIP) when Internet
technology is used.

Desktop sharing lets remote workers see and interact with a graphical computer screen. This
makes it easy for two or more people who work far apart to read and write a shared blackboardor
write a report together.
c) Doing Business Electronically: Airlines, bookstores, and other retailers have discovered that many
customers like the convenience of shopping from home.

2. Home Network Applications

a) Access to remote information: Internet access provides home users with connectivity to remote
computers.As with companies, home users can access information, communicate with other
people, and buy products and services with e-commerce

b) Person to person Communication: Peer-to-peer communication is often used to share


music and videos.
one of the most popular Internet applications of all, email, is inherently peer-to-peer. This form of
communication is likely to grow considerably in the future.

Any teenager worth his or her salt is addicted to instant messaging. This facility, derived from the
UNIX talk program in use since around 1970, allows two people to type messages at each other in
real time. There are multi-person messaging services too, such as the Twitter service that lets
people send short text messages called ‘‘tweets’’ to their circle of friends or other willing audiences.

person-to-person communications and accessing information are social network applications like
Facebook

c) Interactive Entertainment

d) Electronic Commerce e-commerce is widely used is access to financial institutions.

Many people already pay their bills, manage their bank accounts, and handle their investments
electronically.

3. Mobile Users: Mobile computers, such as laptop and handheld computers, are one of the

fastest-growing segments of the computer industry.


4. Social Issues

Social networks, message boards, content sharing sites, and a host of other applications allow people to
share their views with like-minded individuals.

The trouble comes with topics that people actually care about, like politics, religion, or sex. Views that are
publicly posted may be deeply offensive to somepeople.

Worse yet, they may not be politically correct. Furthermore, opinions need not be limited to text; high-
resolution color photographs and video clips are easily shared over computer networks. Some people take a
live-and-let-live view,but others feel that posting certain material (e.g., verbal attacks on particular

countries or religions, pornography, etc.) is simply unacceptable and that such content must be censored.
Different countries have different and conflicting laws in this area.

2) What is Broadcast and point to point links


There are two types of transmission technology that are in widespread use:
Broadcast links
Point-to-point links.
Point-to-point links connect individual pairs of machines. To go from the source to the destination
on a network made up of point-to-point links, short messages, called packets in certain contexts,
may have to first visit one or more intermediate machines..Point-to-pointtransmission with exactly
one sender and exactly one receiver is sometimes called unicasting.
Broadcast network, the communication channel is shared by all the machines on the network;
packets sent by any machine are received by all the others. An address field within each packet
specifies the intended recipient. Upon receiving a packet, a machine checks the address field. If
the packet is intended for the receiving machine, that machine processes the packet; if the packet
is intended for some other machine, it is just ignored. A wireless network is a common example of
a broadcast link, with communication shared over a coverage region that depends on the wireless
channel and the transmitting machine.

4) Define ARPANET
The Advanced Research Projects Agency (ARPA)Network in the Department of Defense (DoD)
was interestedin finding a way to connect computers so that the researchers they funded could share
their findings,thereby reducing costs and eliminating duplication of effort.

5) Differentiate internet and intranet

The internet is a globally-connected network of computers that enables people to share information
and communicate with each other. An intranet, on the other hand, is a private and internal network
that enables people to store, organize, and share information within an organization.

6) What is LAN and WAN


Local Area Networks
A LAN is a privately owned network that operates within and nearby a single building like a home,
office or factory. LANs are widely used to connect personal computers and consumer electronics
to let them share resources (e.g., printers) and exchange information. When LANs are used by
companies, they are called enterprise networks. Wireless LANs are also popular where each
computer communicates with the device called an AP (Access Point), wireless router, or base
station which relays packets between the wireless computers and also between them and the
6) What is LAN and WAN
Local Area Networks
A LAN is a privately owned network that operates within and nearby a single building like a home,
office or factory. LANs are widely used to connect personal computers and consumer electronics
to let them share resources (e.g., printers) and exchange information. When LANs are used by
companies, they are called enterprise networks. Wireless LANs are also popular where each
computer communicates with the device called an AP (Access Point), wireless router, or base
station which relays packets between the wireless computers and also between them and the

Internet. There is a standard for wireless LANs called IEEE 802.11, popularlyknown as
WiFi andit runs at speed from 11 to hundreds of Mbps. Wired LANsuse a range of different
transmission technologies. Most of them use copper wires, but some use optical fiber.
Wide Area Network
A WAN (Wide Area Network) spans a large geographical area, often a country
or continent. In most WANs, the subnet consists of two distinct components:
transmission lines and switching elements. Transmission lines move bits
between machines. They can be made of copper wire, optical fiber, or even
radio links. Most companies do not have transmission lines lying about, so
instead they lease the lines from a telecommunications company. Switching
elements, or just switches, are specialized computers that connect two or more
transmission lines.
LONG QUESTION AND ANSWERS
1) Describe about Network Hardware and Network Software.
Physical Topology
The term physical topology refers to the way in which a network is laid out physically. One or more
devices connect to a link; two or more links form a topology. The topology of a network is the
geometric representation of the relationship of all the links and linking devices (usually called
nodes) to one another. There are four basic topologies possible: mesh, star, bus, and ring

Mesh: In a mesh topology, every device has a dedicated point-to-point link to every other device.
The term dedicated means that the link carries traffic only between the two devices it connects. To
find the number of physical links in a fully connected mesh network with n nodes, we first consider
that each node must be connected to every other node. Node 1 must be connected to n - I nodes,
node 2 must be connected to n – 1 nodes, and finally node n must be connected to n - 1 nodes. We
need n(n - 1) physical links. However, if each physical link allows communication in both directions
(duplex mode), we can divide the number of links by 2. In other words, we can say that in a mesh
topology, we need n(n -1) /2 duplex-mode links.
To accommodate that many links, every device on the network must have n – 1 input/output
(VO) ports to be connected to the other n - 1 stations.
Mesh: In a mesh topology, every device has a dedicated point-to-point link to every other device.
The term dedicated means that the link carries traffic only between the two devices it connects. To
find the number of physical links in a fully connected mesh network with n nodes, we first consider
that each node must be connected to every other node. Node 1 must be connected to n - I nodes,
node 2 must be connected to n – 1 nodes, and finally node n must be connected to n - 1 nodes. We
need n(n - 1) physical links. However, if each physical link allows communication in both directions
(duplex mode), we can divide the number of links by 2. In other words, we can say that in a mesh
topology, we need n(n -1) /2 duplex-mode links.
To accommodate that many links, every device on the network must have n – 1 input/output
(VO) ports to be connected to the other n - 1 stations.
Advantages:
1. The use of dedicated links guarantees that each connection can carry its own data load, thus
eliminating the traffic problems that can occur when links must be shared by multiple
devices.
2. A mesh topology is robust. If one link becomes unusable, it does not incapacitate the entire
system. Third, there is the advantage of privacy or security. When every message travels
along a dedicated line, only the intended recipient sees it. Physical boundaries prevent other
users from gaining access to messages. Finally, point-to-point links make fault
identification and fault isolation easy. Traffic can be routed to avoid links with suspected
problems. This facility enables the network manager to discover the precise location of the
fault and aids in finding its cause and solution.
Disadvantages:
1. Disadvantage of a mesh are related to the amount of cabling because every device must be
connected to every other device, installation and reconnection are difficult.
2. Second, the sheer bulk of the wiring can be greater than the available space (in walls,
ceilings, or floors) can accommodate. Finally, the hardware required to connect each link
(I/O ports and cable) can be prohibitively expensive.
For these reasons a mesh topology is usually implemented in a limited fashion, for example, as a
backbone connecting the main computers of a hybrid network that can include several other
topologies.

Star Topology:
In a star topology, each device has a dedicated point-to-point link only to a central
controller, usually called a hub. The devices are not directly linked to one another. Unlike a mesh
topology, a star topology does not allow direct traffic between devices. The controller acts as an
exchange: If one device wants to send data to another, it sends the data to the controller, which then
relays the data to the other connected device .
A star topology is less expensive than a mesh topology. In a star, each device needs only one link
and one I/O port to connect it to any number of others. This factor also makes it easy to install and
reconfigure. Far less cabling needs to be housed, and additions, moves, and deletions involve only
one connection: between that device and the hub.
Other advantages include robustness. If one link fails, only that link is affected. All other links
remain active. This factor also lends itself to easy fault identification and fault isolation. As long as
the hub is working, it can be used to monitor link problems and bypass defective links.

One big disadvantage of a star topology is the dependency of the whole topology on one single
point, the hub. If the hub goes down, the whole system is dead. Although a star requires far less
cable than a mesh, each node must be linked to a central hub. For this reason, often more cabling is
required in a star than in some other topologies (such as ring or bus).

Bus Topology:
The preceding examples all describe point-to-point connections. A bus topology, on the
other hand, is multipoint. One long cable acts as a backbone to link all the devices in a network

Nodes are connected to the bus cable by drop lines and taps. A drop line is a connection
running between the device and the main cable. A tap is a connector that either splices into the main
cable or punctures the sheathing of a cable to create a contact with the metallic core. As a signal
travels along the backbone, some of its energy is transformed into heat. Therefore, it becomes
weaker and weaker as it travels farther and farther. For this reason there is a limit on the number of
taps a bus can support and on the distance between those taps.
Advantages of a bus topology include ease of installation. Backbone cable can be laid along the
most efficient path, then connected to the nodes by drop lines of various lengths. In this way, a bus
uses less cabling than mesh or star topologies. In a star, for example, four network devices in the
same room require four lengths of cable reaching all the way to the hub. In a bus, this redundancy
is eliminated. Only the backbone cable stretches through the entire facility. Each drop line has to
reach only as far as the nearest point on the backbone.
Disadvantages include difficult reconnection and fault isolation. A bus is usually designed to be
optimally efficient at installation. It can therefore be difficult to add new devices. Signal reflection
at the taps can cause degradation in quality. This degradation can be controlled by limiting the
number and spacing of devices connected to a given length of cable. Adding new devices may
therefore require modification or replacement of the backbone.
In addition, a fault or break in the bus cable stops all transmission, even between devices on the
same side of the problem. The damaged area reflects signals back in the direction of origin, creating
noise in both directions.
Bus topology was the one of the first topologies used in the design of early local area networks.
Ethernet LANs can use a bus topology, but they are less popular.
Ring Topology In a ring topology, each device has a dedicated point-to-point connection with
only the two devices on either side of it. A signal is passed along the ring in one direction, from
device to device, until it reaches its destination. Each device in the ring incorporates a repeater.
When a device receives a signal intended for another device, its repeater regenerates the bits and
passes them along
A ring is relatively easy to install and reconfigure. Each device is linked to only its immediate neighbors (either
physically or logically). To add or delete a device requires changing only two connections. The only constraints are
media and traffic considerations (maximum ring length and number of devices). In addition, fault isolation is
simplified. Generally in a ring, a signal is circulating at all times. If one device does not receive a signal within a
specified period, it can issue an alarm. The alarm alerts the network operator to the problem and its location.
However, unidirectional traffic can be a disadvantage. In a simple ring, a break in the ring (such as a disabled
station) can disable the entire network. This weakness can be solved by using a dual ring or a switch capable of closing
off the break. Ring topology was prevalent when IBM introduced its local-area network Token Ring. Today, the need
for higher-speed LANs has made this topology less popular. Hybrid Topology A network can be hybrid. For example,
we can have a main star topology with each branch connecting several stations in a bus topology as shown in Figure
Network Software
Protocol Hierarchies
To reduce their design complexity, most networks are organized as a stack of layers or levels, each
one built upon the one below it. The number of layers, the name of each layer, the contents of each
layer, and the function of each layer differ from network to network. The purpose of each layer is
to offer certain services to the higher layers while shielding those layers from the details of how
the offered services are actually implemented. In a sense, each layer is a kind of virtual machine,
-offering certain services to the layer above it. When layer n on one machine carries on a
conversation with layer n on another machine, the rules and conventions used in this conversation
are collectively known as the layer n protocol. Basically, a protocol is an agreement between the
communicating parties on how communication is to proceed. Between each pair of adjacent layers
is an interface. The interface defines which primitive operations and services the lower layer makes
available to the upper one.
A set of layers and protocols is called a network architecture. A list of the protocols used by a
certain system, one protocol per layer, is called a protocol stack.

 In 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.
 A protocol provides a communication service that the process use to exchange
messages.
 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.
 Protocol layering is that it allows us to separate the services from the
implementation.
 A layer needs to be able to receive a set of services from the lower layer and to
give the services to the upper layer.
 Any modification in one layer will not affect the other layers.

Basic Elements of Layered Architecture


 Service: It is a set of actions that a layer provides to the higher layer.
 Protocol: It defines a set of rules that a layer uses to exchange the information
with peer entity. These rules mainly concern about both the contents and order of
the messages used.
 Interface: It is a way through which the message is transferred from one layer to
another layer.
Features of Protocol Layering
1. It decomposes the problem of building a network into more
manageable components.
2. It provides a more modular design.

Principles of Protocol Layering


1. The first principle dictates that if we want bidirectional communication,
we needto make each layer so that it is able to perform two opposite
tasks, one in each direction.
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
Design Issues for the Layers
Reliability is the design issue of making a network that operates correctly even though
it is made up of a collection of components that are themselves unreliable.
Mechanism for finding errors in received information uses codes for error detection.
Information that is incorrectly received can then be retransmitted until it is received
correctly. More powerful codes allow for error correction, where the correct message is
recovered from the possibly incorrect bits that were originally received.
Another issue is finding a working path through a network. Often there are multiple paths
betweena source and destination, and in a large network, there may be some links or
routers that are broken.The network should automatically make this decision. This topic
is called routing.
Since there are many computers on the network, every layer needs a mechanism for
identifying the senders and receivers that are involved in a particular message. This
mechanism is called addressing or naming, in the low and high layers.
The network should continue to work well even when the network gets large. It is said
to be scalable. Another design issue is resource allocation. Networks provide a service
to hosts from their underlying resources, such as the capacity of transmission lines. To
do this well, they need mechanisms that divide their resources so that one host does not
interfere with another too much.A service is formally specified by a set of primitives
(operations) available to user processes to access the service. These primitives tell the
service to perform some action or report on an actiontaken by a peer entity.
Connection Oriented and Connectionless
Both Connection-oriented service and Connection-less service are used for the connection
establishment between two or more two devices. These types of services are offered by the network
layer.
Connection-oriented service is related to the telephone system. It includes connection establishment
and connection termination. In a connection-oriented service, the Handshake method is used to
establish the connection between sender and receiver.

Connection-less service is related to the postal system. It does not include any connection
establishment and connection termination. Connection-less Service does not give a guarantee
of reliability. In this, Packets do not follow the same path to reach their destination.
Service Primitives
A service is formally specified by a set of primitives (operations) available touser processes to access the
service. These primitives tell the service to perform some action or report on an action taken by a peer entity.
If the protocol stack is located in the operating system, as it often is, the primitives are normally system
calls. These calls cause a trap to kernel mode, which then turns control of the machine
over to the operating system to send the necessary packets
2) Explain the functionality of each layer in OSI reference model.
each layer in OSI reference model.

OSI Reference Model

o OSI stands for Open System Interconnection.


o It is a reference model that describes how information from a software application
in one computer moves through a physical medium to the software application in
another computer.
o OSI consists of seven layers, and each layer performs a particular network
function.
o OSI model was developed by the International Organization for Standardization
(ISO) in 1984, and it is now considered as an architectural model for the inter-

computer communications.
o OSI model divides the whole task into seven smaller and manageable tasks. Each
layer is assigned a particular task.
o Each layer is self-contained, so that task assigned to each layer can be performed
independently.

ORGANIZATION OF THE OSI LAYERS


FUNCTIONS OF THE OSI LAYERS
1. PHYSICAL LAYER

The physical layer coordinates the functions required to transmit a bit stream over a
physical medium.
The physical layer is concerned with the following functions:
 Physical characteristics of interfaces and media - The physical layer defines
the characteristics of the interface between the devices and the transmission
medium.
 Representation of bits - To transmit the stream of bits, it must be encoded to
signals. The physical layer defines the type of encoding.
 Signals: It determines the type of the signal used for transmitting the information.
 Data Rate or Transmission rate - The number of bits sent each second –is also
defined by the physical layer.
 Synchronization of bits - The sender and receiver must be synchronized at the
bit level. Their clocks must be synchronized

 Line Configuration - In a point-to-point configuration, two devices are
connected together through a dedicated link. In a multipoint configuration, a link
is shared between several devices.
 Physical Topology - The physical topology defines how devices are connected to
make a network. Devices can be connected using a mesh, bus, star or ring
topology.
 Transmission Mode - The physical layer also defines the direction of
transmission between two devices: simplex, half-duplex or full-duplex.
2. DATA LINK LAYER

It is responsible for transmitting frames from one node to the next node.
The other responsibilities of this layer are
 Framing - Divides the stream of bits received into data units called frames.
 Physical addressing – If frames are to be distributed to different systems on the
network , data link layer adds a header to the frame to define the sender and
receiver.
 Flow control- If the rate at which the data are absorbed by the receiver is less
than the rate produced in the sender, t he Data link layer imposes a flow ctrl
mechanism.
 Error control- Used for detecting and retransmitting damaged or lost frames and
to prevent duplication of frames. This is achieved through a trailer added at the
end of the frame.
 Medium Access control -Used to determine which device has control over the
link at any given time.

3. NETWORK LAYER
This layer is responsible for the delivery of packets from source to destination.
It determines the best path to move data from source to the destination based on the
network conditions, the priority of service, and other factors.
The other responsibilities of this layer are
 Logical addressing - If a packet passes the network boundary, we need another
addressing system for source and destination called logical address. This
addressing is used to identify the device on the internet.
 Routing – Routing is the major component of the network layer, and it determines
the best optimal path out of the multiple paths from source to the destination.

4. TRANSPORT LAYER

It is responsible for Process to Process delivery. That is responsible for source-to-


destination (end-to-end) delivery of the entire message, It also ensures whether the
message arrives in order or not.
The other responsibilities of this layer are
 Port addressing / Service Point addressing - The header includes an address
called port address / service point address. This layer gets the entire message to
the correct process on that computer.
 Segmentation and reassembly - The message is divided into segments and each
segment is assigned a sequence number. These numbers are arranged correctly on
the arrival side by this layer.

 Connection control - This can either be connectionless or connection oriented.

 The connectionless treats each segment as an individual packet


and delivers to the destination.
 The connection-oriented makes connection on the destination side
before the delivery. After the delivery the termination will be terminated.
 Flow control - The transport layer also responsible for flow control but it
is performed end-to-end rather than across a single link.
 Error Control - Error control is performed end-to-end rather than across the
single link..

5. SESSION LAYER

This layer establishes, manages and terminates connections between applications.


The other responsibilities of this layer are
 Dialog control - Session layer acts as a dialog controller that creates a dialog
between two processes or we can say that it allows the communication between
two processes which can be either half-duplex or full-duplex.
 Synchronization- Session layer adds some checkpoints when transmitting the
data in a sequence. If some error occurs in the middle of the transmission of data,
then the transmission will take place again from the checkpoint. This process is
known as Synchronization and recovery.

6. PRESENTATION LAYER

It is concerned with the syntax and semantics of information exchanged between two
systems.
The other responsibilities of this layer are
 Translation – Different computers use different encoding system, this layer is
responsible for interoperability between these different encoding methods. It will
change the message into some common format.
 Encryption and decryption-It means that sender transforms the original
information to another form and sends the resulting message over the n/w. and
vice versa.
 Compression and expansion-Compression reduces the number of bits contained
in the information particularly in text, audio and video.
7. APPLICATION LAYER
This layer enables the user to access the network. It handles issues such as network
transparency, resource allocation, etc. This allows the user to log on to remote user.
The other responsibilities of this layer are
 FTAM (File Transfer, Access, Management) - Allows user to access files in
a remote host.
 Mail services - Provides email forwarding and storage.
 Directory services - Provides database sources to access information about
various sources and objects.

3) Explain about TCP/IP MODEL


TCP / IP Protocol
 The TCP/IP architecture is also called as Internet architecture.
 It is developed by the US Defense Advanced Research Project Agency (DARPA)
for its packet switched network (ARPANET).
 TCP/IP is a protocol suite used in the Internet today. 
 It is a 4-layer model. The layers of TCP/IP are
1. Application layer
2. Transport Layer (TCP/UDP)
3. Internet Layer
4. The Host - to - Network Layer
APPLICATION LAYER
 An application layer incorporates the function of top three OSI layers. An
application layer is the topmost layer in the TCP/IP model.
 It is responsible for handling high-level protocols, issues of representation.
 This layer allows the user to interact with the application.
 When one application layer protocol wants to communicate with another
application layer, it forwards its data to the transport layer. 
 Protocols such as FTP, HTTP, SMTP, POP3, etc running in the application layer
provides service to other program running on top of application layer 

TRANSPORT LAYER
 The transport layer is responsible for the reliability, flow control, and correction
of data which is being sent over the network.
 The two protocols used in the transport layer are User Datagram protocol and
Transmission control protocol.
o UDP – UDP provides connectionless service and end-to-end delivery of
transmission. It is an unreliable protocol as it discovers the errors but
not specify the error.
o TCP – TCP provides a full transport layer services to applications. TCP
is a reliable protocol as it detects the error and retransmits the
damaged frames.

INTERNET LAYER
 The internet layer is the second layer of the TCP/IP model.
 An internet layer is also known as the network layer.
 The main responsibility of the internet layer is to send the packets from any
network, and they arrive at the destination irrespective of the route they take.
 Internet layer handle the transfer of information across multiple networks through
router and gateway .
 IP protocol is used in this layer, and it is the most significant part of the entire
TCP/IP suite.

HOST - TO - NETWORK LAYER


 The network interface layer is the lowest layer of the TCP/IP model.
 This layer is the combination of the Physical layer and Data Link layer defined
in the OSI reference model. 
 It defines how the data should be sent physically through the network.
 This layer is mainly responsible for the transmission of the data between two
devices on the same network.
 The functions carried out by this layer are encapsulating the IP datagram into
frames transmitted by the network and mapping of IP addresses into physical
addresses.
 The protocols used by this layer are Ethernet, token ring, FDDI, X.25, frame
relay. 
4) Compare and contrast the OSI and TCP/IP reference models.

Following are the differences between OSI and TCP/IP Reference Model −

OSI TCP/IP

OSI represents Open System TCP/IP model represents the Transmission


Interconnection. Control Protocol / Internet Protocol.

OSI is a generic, protocol independent TCP/IP model depends on standard protocols


standard. It is acting as an interaction gateway about which the computer network has created.
between the network and the final-user. It is a connection protocol that assigns the
network of hosts over the internet.

The OSI model was developed first, and then The protocols were created first and then built
protocols were created to fit the network the TCP/IP model.
architecture’s needs.

It provides quality services. It does not provide quality services.

The OSI model represents defines It does not mention the services, interfaces,
administration, interfaces and conventions. It and protocols.
describes clearly which layer provides
services.

The protocols of the OSI model are better The TCP/IP model protocols are not hidden,
unseen and can be returned with another and we cannot fit a new protocol stack in it.
appropriate protocol quickly.

It is difficult as distinguished to TCP/IP. It is simpler than OSI.

It provides both connection and connectionless It provides connectionless transmission in the


OSI TCP/IP

oriented transmission in the network layer; network layer and supports connecting and
however, only connection-oriented connectionless-oriented transmission in the
transmission in the transport layer. transport layer.

It uses a horizontal approach. It uses a vertical approach.

The smallest size of the OSI header is 5 bytes. The smallest size of the TCP/IP header is 20
bytes.

Protocols are unknown in the OSI model and In TCP/IP, returning protocol is not difficult.
are returned while the technology modifies.
5) Describe guided and unguided transmission media.
Explain about various transmission media in physical layer with a neat sketch.

Transmission Media

Transmission media is a communication channel that carries the information fromthe sender to the receiver
o Data is transmitted through the electromagnetic signals.
o The main functionality of the transmission media is to carry the information
in the form of bits (Either as Electrical signals or Light pulses).
o It is a physical path between transmitter and receiver in data communication.
o The characteristics and quality of data transmission are determined by the
characteristics of medium and signal.
o Transmission media is of two types : Guided Media (Wired) and UnGuided
Media (wireless).
o In guided (wired) media, medium characteristics are more important whereas, in
unguided (wireless) media, signal characteristics are more important.
o Different transmission media have different properties such as bandwidth, delay,
cost and ease of installation and maintenance.
o The transmission media is available in the lowest layer of the OSI reference
model, i.e., Physical layer.

FACTORS FOR DESIGNING THE TRANSMISSION MEDIA


o Bandwidth: All the factors are remaining constant, the greater the bandwidth of a
medium, the higher the data transmission rate of a signal.
o Transmission impairment: When the received signal is not identical to the
transmitted one due to the transmission impairment. The quality of the signals
will get destroyed due to transmission impairment.
o Interference: An interference is defined as the process of disrupting a signal
when it travels over a communication medium on the addition of some unwanted
signal

GUIDED MEDIA
 It is defined as the physical medium through which the signals are transmitted.
 It is also known as Bounded media.
 Types of Guided media: Twisted Pair Cable, Coaxial Cable, Fibre Optic Cable

TWISTED PAIR CABLE

 Twisted pair is a physical media made up of a pair of cables twisted with each
other.
 A twisted pair cable is cheap as compared to other transmission media.
 Installation of the twisted pair cable is easy, and it is a lightweight cable.
 The frequency ranges for twisted pair cable is from 0 to 3.5KHz.
 A twisted pair consists of two insulated copper wires arranged in a regular spiral
pattern.
Unshielded Twisted Pair
An unshielded twisted pair is widely used in telecommunication.
Following are the categories of the unshielded twisted pair cable:
o Category 1: Suports low-speed data.
o Category 2: It can support upto 4Mbps.
o Category 3: It can support upto 16Mbps.
o Category 4: It can support upto 20Mbps.
o Category 5: It can support upto 200Mbps.

Advantages :
o It is cheap.
o Installation of the unshielded twisted pair is easy.
o It can be used for high-speed LAN.

Disadvantage:
o This cable can only be used for shorter distances because of attenuation.

Shielded Twisted Pair

A shielded twisted pair is a cable that contains the mesh surrounding the wire that allows
the higher transmission rate.
Advantages :
o The cost of the shielded twisted pair cable is not very high and not very low.
o Installation of STP is easy.
o It has higher capacity as compared to unshielded twisted pair cable.
o It has a higher attenuation.
o It is shielded that provides the higher data transmission rate.

Disadvantages:
o It is more expensive as compared to UTP and coaxial cable.
o It has a higher attenuation rate.

COAXIAL CABLE

o Coaxial cable(Coax) is a very commonly used transmission media, for example,


TV wire is usually a coaxial cable.

o The name of the cable is coaxial as it contains two conductors parallel to each
other.
o It has a higher frequency as compared to Twisted pair cable.
o The inner conductor of the coaxial cable is made up of copper, and the outer
conductor is made up of copper mesh.
o The middle core is made up of non-conductive cover that separates the inner
conductor from the outer conductor.
o The middle core is responsible for the data transferring whereas the copper mesh
prevents from the EMI(Electromagnetic interference).
o Common applications of coaxial cable are Cable TV networks and traditional
Ethernet LANs.

Coaxial Cable Standards


 Coaxial cables are categorized by their Radio Government (RG) ratings.
 Each RG number denotes a unique set of physical specifications, including the
wire gauge of the inner conductor, the thickness and type of the inner insulator,
the construction of the shield, and the size and type of the outer casing.
 Each cable defined by an RG rating is adapted for a specialized function.

Types of Coaxial cable :


1. Baseband transmission: It is defined as the process of transmitting a single
signal at high speed.
2. Broadband transmission: It is defined as the process of transmitting multiple
signals simultaneously.

Advantages :

o The data can be transmitted at high speed.


o It has better shielding as compared to twisted pair cable.
o It provides higher bandwidth.
Disadvantages :
o It is more expensive as compared to twisted pair cable.
o If any fault occurs in the cable causes the failure in the entire network.

FIBRE OPTIC CABLE

o Fibre optic cable is a cable that uses electrical signals for communication.
o Fibre optic is a cable that holds the optical fibres coated in plastic that are used to
send the data by pulses of light.
o The plastic coating protects the optical fibres from heat, cold, electromagnetic
interference from other types of wiring.
o Fibre optics provide faster data transmission than copper wires.
Basic elements of Fibre optic cable:
o Core: The optical fibre consists of a narrow strand of glass or plastic known as
a core. A core is a light transmission area of the fibre. The more the area of the
core, the more light will be transmitted into the fibre.
o Cladding: The concentric layer of glass is known as cladding. The main
functionality of the cladding is to provide the lower refractive index at the core
interface as to cause the reflection within the core so that the light waves are
transmitted through the fibre.
o Jacket: The protective coating consisting of plastic is known as a jacket. The
main purpose of a jacket is to preserve the fibre strength, absorb shock and extra
fibre protection.

Advantages:
o Greater Bandwidth
o Less signal attenuation
o Immunityto electromagnetic interference
o Resistance to corrosive materials
o Light weight
o Greater immunity to tapping
Disadvantages :
o Requires Expertise for Installation and maintenance
o Unidirectional light propagation.
o Higher Cost.

Propagation Modes of Fibre Optics


 Current technology supports two modes (multimode and single mode) for
propagating light along optical channels, each requiring fiber with different
physicalcharacteristics.
 Multimode can be implemented in two forms: step-index or graded-index.

Multimode Propagation
 Multimode is so named because multiple beams from a light source move through
the core in different paths.
 How these beams move within the cable depends on the structure of the core.

Single-Mode Propagation

 Single-mode uses step-index fiber and a highly focused source of light that limits
beams to a small range of angles, all close to the horizontal.
 The single-mode fiber itself is manufactured with a much smaller diameter than
that of multimode fiber, and with substantially lower density(index of refraction).
 The decrease in density results in a critical angle that is close enough to 90° to
make the propagation of beams almost horizontal.
 In this case, propagation of different beams is almost identical, and delays are
negligible. All the beams arrive at the destination “together” and can be
recombined with little distortion to the signal.
UNGUIDED MEDIA
o An unguided transmission transmits the electromagnetic waves without using any
physical medium. Therefore it is also known as wireless transmission.
o In unguided media, air is the media through which the electromagnetic energy
can flow easily.

Unguided transmission is broadly classified into three categories : Radio Waves, Microwaves ,
Infrared

RADIO WAVES

o Radio waves are the electromagnetic waves that are transmitted in all the
directions of free space.
o Radio waves are omnidirectional, i.e., the signals are propagated in all the
directions.
o The range in frequencies of radio waves is from 3Khz to 1Ghz.
o In the case of radio waves, the sending and receiving antenna are not aligned, i.e.,
the wave sent by the sending antenna can be received by any receiving antenna.
o An example of the radio wave is FM radio.

Applications of Radio waves:


o A Radio wave is useful for multicasting when there is one sender and many
receivers.
o An FM radio, television, cordless phones are examples of a radio wave.

Advantages of Radio waves:


o Radio transmission is mainly used for wide area networks and mobile cellular
phones.
o Radio waves cover a large area, and they can penetrate the walls.
o Radio transmission provides a higher transmission rate.

MICROWAVES
Microwaves are of two types - Terrestrial microwave & Satellite microwave

Terrestrial Microwave
o Terrestrial Microwave transmission is a technology that transmits the focused
beam of a radio signal from one ground-based microwave transmission antenna to
another.
o Microwaves are the electromagnetic waves having the frequency in the range
from 1GHz to 1000 GHz.
o Microwaves are unidirectional as the sending and receiving antenna is to be
aligned, i.e., the waves sent by the sending antenna are narrowly focused.
o In this case, antennas are mounted on the towers to send a beam to another
antenna which is km away.
o It works on the line of sight transmission, i.e., the antennas mounted on the
towers are at the direct sight of each other.

Characteristics of Terrestrial Microwave:


o Frequency range: The frequencyrange of terrestrial microwave is from 4-6 GHz
to 21-23 GHz.
o Bandwidth: It supports the bandwidth from 1 to 10 Mbps.
o Short distance: It is inexpensive for short distance.
o Long distance: It is expensive as it requires a higher tower for a longer distance.
o Attenuation: Attenuation means loss of signal. It is affected by environmental
conditions and antenna size.

Advantages of Terrestrial Microwave:


o Microwave transmission is cheaper than using cables.
o It is free from land acquisition as it does not require any land for the installation
of cables.
o Microwave transmission provides an easy communication in terrains as the
installation of cable in terrain is quite a difficult task.
o Communication over oceans can be achieved by using microwave transmission.

Disadvantages of Terrestrial Microwave:


o Eavesdropping.
o Out of phase signal
o Susceptible to weather condition
o Bandwidth limited

Satellite Microwave
o A satellite is a physical object that revolves around the earth at a known height.
o Satellite communication is more reliable nowadays as it offers more flexibility
than cable and fibre optic systems.
o We can communicate with any point on the globe by using satellite
communication.
o The satellite accepts the signal that is transmitted from the earth station, and
it amplifies the signal. The amplified signal is retransmitted to another earth station.

Advantages of Satellite Microwave:


o The coverage area of a satellite microwave is more than the terrestrial microwave.
o The transmission cost of the satellite is independent of the distance from
the centre of the coverage area.
o Satellite communication is used in mobile and wireless
communication applications.
o It is easy to install.
o It is used in a wide variety of applications such as weather forecasting, radio/TV
signal broadcasting, mobile communication, etc.

Disadvantages of Satellite Microwave:


o Satellite designing and development requires more time and higher cost.
o The Satellite needs to be monitored and controlled on regular periods so that
it remains in orbit.
o The life of the satellite is about 12-15 years. Due to this reason, another launch of
the satellite has to be planned before it becomes non-functional.

INFRARED WAVES
o An infrared transmission is a wireless technology used for communication over
short ranges.
o The frequency of the infrared in the range from 300 GHz to 400 THz.
o It is used for short-range communication such as data transfer between two cell
phones, TV remote operation, data transfer between a computer and cell phone
and devices that resides in the same closed area.

Characteristics of Infrared:
o It supports high bandwidth, and hence the data rate will be very high.
o Infrared waves cannot penetrate the walls. Therefore, the infrared communication
in one room cannot be interrupted by the nearby rooms.
o An infrared communication provides better security with minimum interference.
o Infrared communication is unreliable outside the building because the sun rays
will interfere with the infrared waves.
UNIT-2
SHORT QUESTION & ANSWERS
1) Explain in brief about the design issues in the data link layer.

specific responsibilities of the data link layer include framing, addressing, flow control, error
control, and media access control.

.1 DESIGN ISSUES:
 Frame synchronization: Data are sent in blocks called frames. The beginning and end of
each frame must be recognizable.
 Flow control: The sending station must not send frames at a rate faster than the receiving
station can absorb them.
 Error control: Bit errors introduced by the transmission system should be corrected.
 Addressing: On a shared link, such as a local area network (LAN), the identity of the two
stations involved in a transmission must be specified.
 Access Control: It is usually not desirable to have a physically separate communications
path for control information. Accordingly, the receiver must be able to distinguish control
information from the data being transmitted.
 Link management: The initiation, maintenance, and termination of a sustained data
exchange require a fair amount of coordination and cooperation among stations.
Procedures for the management of this exchange are required.

2) Define Framing in datalink layer

 The data link layer divides the stream of bits received from the network layer into
manageable data units called frames.
 When a frame arrives at the destination, the checksum is recomputed.

 If the newly-computed checksum is different from the one contained in the frame,
the data link layer knows that an error has occurred and takes steps to deal with it
(e.g., discarding the bad frame and possibly also sending back an error report).

 Framing can be done in two ways:


1. Fixed Size Framing
2. Variable Size Framing
 Fixed Size Framing:
 In fixed-size framing, there is no need for defining the boundaries of the frames;
the size itself can be used as a delimiter.

Ex: ATM Cell which is of 5


Variable-Size Framing:
In variable-size framing, we need a way to define the end of the frame and the beginning of the
next.

3) Explain the concept of Bit Stuffing Character Stuffing


Character Stuffing: Character stuffing uses the special start/end characters for framing and allows
those characters in the message also.
The method is for the sender to stuff an extra special character whenever the start or end character
occurs naturally so that within the message the special character always occurs in pairs.
The receiver recognizes the single special character as start/end and removes from the message the
first special character from pairs received.

Figure: Character Stuffing


Bit Oriented Framing Protocols: A protocol in which the data frame is interpreted as a sequence
of bits.
Starting & ending Flags With Bit Stuffing:
In this Method , Each frame begins & ends with a special bit pattern 01111110 called Flags.
Bit Stuffing: Whenever the sender's data link layer encounters five consecutive 1s in the data, it
automatically stuffs a zero bit into the outgoing bit stream. This technique is called bit stuffing.
When the receiver sees five consecutive 1s in the incoming data stream, followed by a zero bit, it
automatically destuffs the 0 bit. The boundary between two frames can be determined by locating
the flag pattern.
4) Difference Between Error Correction and Error Detection

ERROR DETECTION AND CORRECTION


 Detection Versus Correction
 Error detection, looks only to see if any error has occurred. The answer is a simple
yes or no. For an error detection method, a single-bit error is the same for us as a
burst error.
 Error correction, know the exact number of bits that are corrupted and more
importantly, their location in the message. The number of the errors and the size of
the message are important factors. If we need to correct one single error in an 8-bit
data unit, we need to consider eight possible error locations; if we need to correct
two errors in a data unit of the same size, we need to consider 28 possibilities.
It allows the receiver to inform the sender of any frames lost or damaged in
transmission and coordinates the retransmission of those frames by the sender

5) Write about ALOHA

 There are two forms of ALOHA


1. Pure ALOHA
2. Slotted ALOHA

 Pure ALOHA
 The original ALOHA protocol is called pure ALOHA. This is a simple, but
elegant protocol.
 The idea is that each station sends a frame whenever it has a frame to send.
 Since there is only one channel to share, there is the possibility of collision
between frames from different stations.
 A collision involves two or more stations.
Figure: Pure ALOHA

 The pure ALOHA protocol relies on acknowledgments from the receiver.


o When a station sends a frame, it expects the receiver to send an
acknowledgment.
o If the acknowledgment does not arrive after a time-out period, the
station assumes that the frame (or the acknowledgment) has been
destroyed and resends the frame.
o If all these stations try to resend their frames after the time-out, the frames
will collide again.

6) Define FDM and TDM


Frequency Division Multiplexing (FDM): If there are N users, the bandwidth is divided into N
equal-sized portions, each user being assigned one portion.

Drawback of FDM: FDM is a simple and efficient allocation mechanism. But, when the number of
senders is large and continuously varying or the traffic is bursty.

Time Division Multiplexing: Each user is statically allocated every Nth time slot. If a user does
not use the allocated slot. The same holds if we split up the networks physically.

7) Define BRIDGES
 A bridge operates in both the physical and the data link layer.
 In physical layer it regenerates the signal it receives.
 In data link layer, the bridge can check the physical (MAC) addresses (source and
destination) contained in the frame.

8) Difference Between CSMA/CA and CSMA/CD


CSMA/CD CSMA/CA

Whereas CSMA / CA is effective before a


CSMA / CD is effective after a collision.
collision.

Whereas CSMA / CA is commonly used in wireless


CSMA / CD is used in wired networks.
networks.

Whereas CSMA/ CA minimizes the possibility of


It only reduces the recovery time.
collision.

CSMA / CD resends the data frame whenever Whereas CSMA / CA will first transmit the intent
a conflict occurs. to send for data transmission.

CSMA / CD is used in 802.3 standard. While CSMA / CA is used in 802.11 standard.

It is more efficient than simple CSMA(Carrier While it is similar to simple CSMA(Carrier Sense
Sense Multiple Access). Multiple Access).

It is the type of CSMA to detect the collision It is the type of CSMA to avoid collision on a
on a shared channel. shared channel.

It is work in MAC layer. It is also work in MAC layer.


LONG QUESTION AND ANSWERS
1) Explain in detail about Elementary data link protocols.
OR
Explain and demonstrate a simplex stop and wait protocol for noisy channel.
OR
Explain and demonstrate Selective repeat sliding window Protocol with an example?
OR
Explain in brief about the Sliding Window protocols.
OR
Explain about GBN Sliding Window Protocol
 Elementary Data Link Protocols:
 Stop-and-Wait Flow Control
o The simplest form of flow control, known as stop-and-wait flow control.
o A source entity transmits a frame. After the destination entity receives the
frame, it indicates its willingness to accept another frame by sending back
an acknowledgment to the frame just received.
o The source must wait until it receives the acknowledgment before sending
the next frame.
o The destination can thus stop the flow of data simply by withholding
acknowledgment.
Figure: Stop-and-Wait Protocol
o Sender keeps a copy of the last frame until it receives an acknowledgement.
For identification, both data frames and acknowledgements (ACK) frames
are numbered alternatively 0 and 1.
o Sender has a control variable (S) that holds the number of the recently sent
frame. (0 or 1)
o Receiver has a control variable ® that holds the number of the next frame
expected (0 or 1).
o Sender starts a timer when it sends a frame. If an ACK is not received within
a allocated time period, the sender assumes that the frame was lost or
damaged and resends it
o Receiver send only positive ACK if the frame is intact.
o ACK number always defines the number of the next expected frame

Figure: Flow diagram of Stop-and-Wait Protocol


o Limitations:
 The Buffer size may be limited.
 At a time, only one frame at a time can be in transit. This means low
utilization of bandwidth.
 Piggy Backing:
o A method to combine a data frame with ACK.
o Station A and B both have data to send.
o Instead of sending separately, station A sends a data frame that includes an
ACK. Station B does the same thing.
o Piggybacking saves bandwidth.

 Sliding Window Protocols


o The stop and wait protocol suffers from a few drawbacks:
1. if the receiver had the capacity to accept more than one frame, its
resources are being underutilized.
2. if the receiver was busy and did not wish to receive any more
packets, it may delay the acknowledgement. However, the timer on
the sender's side may go off and cause an unnecessary
retransmission.
o These drawbacks can be overcome by the sliding window protocols.
o In sliding window protocols the sender's data link layer maintains a 'sending
window' which consists of a set of sequence numbers corresponding to the
frames it is permitted to send.
o Figure: The Sender's Window
o Similarly, the receiver maintains a 'receiving window' corresponding to the
set of frames it is permitted to accept.

Figure: Receiver's Window


o The window size is dependent on the retransmission policy and it may differ
in values for the receiver's and the sender's window.
o The sequence numbers within the sender's window represent the frames sent
but as yet not acknowledged.
o Whenever a new packet arrives from the network layer, the upper edge of
the window is advanced by one.
o When an acknowledgement arrives from the receiver the lower edge is
advanced by one.
o The receiver's window corresponds to the frames that the receiver's data link
layer may accept.
o When a frame with sequence number equal to the lower edge of the window
is received, it is passed to the network layer, an acknowledgement is
generated and the window is rotated by one.
o If however, a frame falling outside the window is received, the receiver's
data link layer has two options. It may either discard this frame and all
subsequent frames until the desired frame is received or it may accept these
frames and buffer them until the appropriate frame is received and then pass
the frames to the network layer in sequence.
Figure: Example of Sliding-Window Protocol

 Go-back-N ARQ protocol:


o If a frame is lost or received in error, the receiver may simply discard allsubsequent
frames, sending no acknowledgments for the discarded frames.
o In this case the receive window is of size 1. Since no acknowledgements are being
received the sender's window will fill up, the sender will eventually time out and
retransmit all the unacknowledged frames in order starting from the damaged or
lost frame.
o The maximum window size for this protocol can be obtained as follows. Assume
that the window size of the sender is n. So the window will initially contain the
frames with sequence numbers from 0 to (w-1).
o Consider that the sender transmits all these frames and the receiver's data link layer
receives all of them correctly. However, the sender's data link layer does not
receive any acknowledgements as all of them are lost. So the sender will retransmit
all the frames after its timer goes off. However the receiver window has already
advanced to w. Hence to avoid overlap , the sum of the two windows should be
less than the sequence number space.
Figure: Go-back-N ARQ protocol

Figure: Go-back-N with lost frame


 Selective Repeat ARQ:
o In this protocol rather than discard all the subsequent frames following a
damaged or lost frame, the receiver's data link layer simply stores them in
buffers.
o When the sender does not receive an acknowledgement for the first frame
it's timer goes off after a certain time interval and it retransmits only the lost
frame.
o Assuming error - free transmission this time, the sender's data link layer will
have a sequence of a many correct frames which it can hand over to the
network layer. Thus there is less overhead in retransmission than in the case
of Go Back n protocol.
o In case of selective repeat protocol the window size may be calculated as
follows. Assume that the size of both the sender's and the receiver's window
is w. So initially both of them contain the values 0 to (w-1).
o Consider that sender's data link layer transmits all the w frames, the
receiver's data link layer receives them correctly and sends
acknowledgements for each of them. However, all the acknowledgments
are lost and the sender does not advance it's window.
o The receiver window at this point contains the values w to (2w-1). To avoid
overlap when the sender's data link layer retransmits, we must have the sum
of these two windows less than sequence number space. Hence, we get the
condition

Figure: Selective-Repeat ARQ


2) What are the different types of error detection methods? Explain the CRC
errordetection technique using generator polynomial x4+x3+1 and data
11100011.
CRC ( Cyclic Redundancy Check):
o One of the most common, and one of the most powerful, error-detecting
codes is the cyclic redundancy check (CRC), which can be described as
follows.
o Given a k-bit block of bits, or message, the transmitter generates an
sequence, known as a frame check sequence (FCS), such that the resulting
frame, consisting of n bits, is exactly divisible by some predetermined
number. The receiver then divides the incoming frame by that number and,
if there is no remainder, assumes there was no error.
o To clarify this, we present the procedure in three equivalent ways: modulo
2 arithmetic, polynomials, and digital logic.
o Modulo 2 Arithmetic: Modulo 2 arithmetic uses binary addition with no
carries, which is just the exclusive-OR (XOR) operation. Binary subtraction
with no carries is also interpreted as the XOR operation.
Ex:

Figure: Modulo 2 Arithmetic: Addition, Subtraction and Multiplication

Figure: Encoder and Decoder in CRC


o At the sender side:
 The encoder takes the dataword and augments it with n - k number
of as. It then divides the augmented dataword by the divisor
 The process of modulo-2 binary division is the same as the familiar
division process. we use for decimal numbers.
 As in decimal division, the process is done step by step. In each step,
a copy of the divisor is XORed with the 4 bits of the dividend.
 The result of the XOR operation (remainder) is 3 bits (in this case),
which is used for the next step after 1 extra bit is pulled down to
make it 4 bits long.
 If the leftmost bit of the dividend (or the part used in each step) is 0,
the step cannot use the regular divisor; we need to use an all-0s
divisor. When there are no bits left to pull down, we have a result.
The 3-bit remainder forms the check bits (r2', rl' and ro). They are
appended to the dataword to create the codeword.

Ex:
 Suppose we want to transmit the information string:
1111101.
 The receiver and sender decide to use the polynomial
pattern, 1101.
 The information string is shifted left by one position less
than the number of positions in the divisor.
 The remainder is found through modulo 2 division (at right)
and added to the information string: 1111101000 + 111 =
1111101111.

Figure: Modulo-2 division


Mapping polynomial to a Binary data word:
o At the receiver side:
 The codeword can change during transmission.
 The decoder does the same division process as the encoder.
 The remainder of the division is the syndrome. If the syndrome is
all 0s, there is no error; the dataword is separated from the received
codeword and accepted. Otherwise, everything is discarded.
 The value of syndrome when no error has occurred; the syndrome is
000. The syndrome is not all 0s.

o CRC standard polynomials:

 Check Sum:
o Checksum is an error detection method.
o The checksum is used in the Internet by several protocols although not at
the data link layer.
o The receiver follows these steps:
 The unit is divided into k sections, each of n bits.
 All sections are added using one’s complement to get the sum
 The sum is complemented.
 If the result is zero, the data are accepted: otherwise rejected.
o The sender follows these steps:
 The unit is divided into k sections, each of n bits.
 All sections are added using one’s complement to get the sum.
 The sum is complemented and becomes the checksum.
 The checksum is sent with the data.

Figure: Checksum
3) Explain in detail about Error correction.
 ERROR CORRECTION:
 Hamming Code:
o Hamming codes provide for Forward Error Correction using a “Block
Parity” i.e, instead of one parity bit send a block of parity bits
o Allows correction of single bit errors.
o This is accomplished by using more than one parity bit.
o Each computed on different combination of bits in the data.
o In hamming code, the redundant bits are added to the original data at all 2ith
position where i=0,1,2... such that 2i<n where n is the no of bits in original
data.
Ex:
o The Redundant bits are calculated as

Figure: Calculation of redundant bits.


Ex
4) In detail, explain the various ALOHA protocols.
ALOHA
 ALOHA, the earliest random access method, was developed at the University of Hawaii in
early 1970.
 It was designed for a radio (wireless) LAN, but it can be used on any shared medium.
 It is obvious that there are potential collisions in this arrangement.
 The medium is shared between the stations. When a station sends data, another station may
attempt to do so at the same time. The data from the two stations collide and become
garbled.
 There are two forms of ALOHA
1. Pure ALOHA
2. Slotted ALOHA

 Pure ALOHA
 The original ALOHA protocol is called pure ALOHA. This is a simple, but elegant
protocol.
 The idea is that each station sends a frame whenever it has a frame to send.
 Since there is only one channel to share, there is the possibility of collision between
frames from different stations.
 A collision involves two or more stations.
Figure: Pure ALOHA

 The pure ALOHA protocol relies on acknowledgments from the receiver.


o When a station sends a frame, it expects the receiver to send an
acknowledgment.
o If the acknowledgment does not arrive after a time-out period, the station
assumes that the frame (or the acknowledgment) has been destroyed and
resends the frame.
o If all these stations try to resend their frames after the time-out, the frames
will collide again.

 Collision Prevention in Pure ALOHA:


o Pure ALOHA dictates that when the time-out period passes, each station
waits a random amount of time before resending its frame.
o After a maximum number of retransmission attempts Kmax' a station must
give up and try later.
o Vulnerable Time: The length of the collision is given by the Vulnerable
Time.
Figure: Vulnerable Time of Pure ALOHA

o Let us assume that the stations send fixed-length frames with each frame
taking Tfr s to send.
o The Above figure gives the vulnerable time of the Station A, Station A sends a
frame at time t. Now imagine station B has already sent a frame between t - Tfr
and t. This leads to a collision between the frames from station A and station
B. The end of B's frame collides with the beginning of A's frame.
o On the other hand, suppose that station C sends a frame between t and t+Tfr.
Here, there is a collision between frames from station A and station C. The
beginning of C's frame collides with the end of A's frame.
o The vulnerable time, during which a collision may occur in pure ALOHA,
is 2 times the frame transmission time.
Pure ALOHA vulnerable time = 2 x Tfr

 Slotted ALOHA
 Slotted ALOHA was invented to improve the efficiency of pure ALOHA.
 In slotted ALOHA we divide the time into slots of Tfr s and force the station to send
only at the beginning of the time slot.
 Because a station is allowed to send only at the beginning of the synchronized time
slot, if a station misses this moment, it must wait until the beginning of the next
time slot. This means that the station which started at the beginning of this slot has
already finished sending its frame.
 There is still the possibility of collision if two stations try to send at the beginning
of the same time slot.
Figure: Slotted ALOHA
 Vulnerable Time: The vulnerable time for slotted ALOHA is one-half that of pure
ALOHA.
Slotted ALOHA vulnerable time = Tfr

Figure: Vulnerable Time of Slotted ALOHA


Figure: Flow Diagram for ALOHA
 Throughput:
o The average number of successful transmissions for slotted ALOHA is S =
G x e-G.
o The maximum throughput Smax is 0.368, when G = 1. In other words, if a
frame is generated during one frame transmission time, then 36.8 percent
of these frames reach their destination successfully. This result can be
expected because the vulnerable time is equal to the frame transmission
time.
o If a station generates only one frame in this vulnerable time (and no other
station generates a frame during this time), the frame will reach its
destination successfully.
The throughput for slotted ALOHA is S =: G x e-G.

5) What is the purpose of CSMA CD? And Explain it.


CSMA/CD (Carrier Sense Multiple Access with Collision Detection):
 The CSMA method does not specify the procedure following a collision. Carrier sense
multiple access with collision detection (CSMA/CD) augments the algorithm to handle the
collision.In this method, a station monitors the medium after it sends a frame to see if the
transmission was successful.If so, the station is finished. If, however, there is a collision, the
frame is sent again.
 To better understand CSMA/CD, let us look at the first bits transmitted by the two stations
involved in the collision. Although each station continues to send bits in the frame until it
detects the collision.

Figure: Collision of the first bit in CSMA/CD


 At time t1, station A has executed its persistence procedure and starts sending the bits of its
frame.
 At time t2, station C has not yet sensed the first bit sent by A. Station C executes its
persistence procedure and starts sending the bits in its frame, which propagate both to the
left and to the right. The collision occurs sometime after time t2 Station C detects a collision
at time t3 when it receives the first bit of A's frame. Station C immediately (or after a short
time, but we assume immediately) aborts transmission.
 Minimum Frame Size: Each frame must be large enough for a sender to detect a collision.
 Energy Level:
 The level of energy in a channel can have three values: zero, normal, and abnormal.
 At the zero level, the channel is idle. This level is also called Idle Period.
 At the normal level, a station has successfully captured the channel and is sending
its frame. This level is called Transmission Period.
 At the abnormal level, there is a collision and the level of the energy is twice the
normal level. This is called Contention Period.
 A station that has a frame to send or is sending a frame needs to monitor the energy
level to determine if the channel is idle, busy, or in collision mode.
Figure: Energy levels in CSMA/CD

Figure: Flow Diagram for CSMA/CD

6) Elucidate the CSMA CA schemes.


CSMA/CA (Carrier Sense Multiple Access with Collision Avoidance):
 The basic idea behind CSMA/CD is that a station needs to be able to receive while
transmitting to detect a collision. The signal from the second station needs to add a
significant amount of energy to the one created by the first station.
 In a wired network, the received signal has almost the same energy as the sent signal
because either the length of the cable is short or there are repeaters that amplify the energy
between the sender and the receiver. This means that in a collision, the detected energy
almost doubles.
 In a wireless network, much of the sent energy is lost in transmission. The received signal
has very little energy. Therefore, a collision may add only 5 to 10 percent additional energy.
This is not useful for effective collision detection.
 Carrier sense multiple access with collision avoidance (CSMA/CA) was invented for this
network.
 Collisions are avoided through the use of CSMA/CA's three strategies:
The Interframe Space, The Contention Window, and Acknowledgments
 Interframe Space:
o Collisions are avoided by deferring transmission even if the channel is
found idle.
o When an idle channel is found, the station does not send immediately.
o It waits for a period of time called the interframe space or IFS.
o The IFS time allows the front of the transmitted signal by the distant station
to reach this station.
o If after the IFS time the channel is still idle, the station can send, but it still
needs to wait a time equal to the contention time.
o The IFS variable can also be used to prioritize stations or frame types. For
example, a station that is assigned a shorter IFS has a higher priority.
 The Contention Window:
o The contention window is an amount of time divided into slots.
o A station that is ready to send chooses a random number of slots as its wait
time. The number of slots in the window changes according to the binary
exponential back-off strategy. This means that it is set to one slot the first
time and then doubles each time the station cannot detect an idle channel
after the IFS time. This is very similar to the p-persistent method except that
a random outcome defines the number of slots taken by the waiting station.
o The contention window is that the station needs to sense the channel after
each time slot.
o If the station finds the channel busy, it does not restart the process; it just
stops the timer and restarts it when the channel is sensed as idle. This gives
priority to the station with the longest waiting time.
 Acknowledgements:
o The data may be corrupted during the transmission. The positive
acknowledgment and the time-out timer can help guarantee that the receiver
has received the frame.

Figure: The Interframe Space, The Contention Window, and


Acknowledgments
 CSMA/CA was mostly intended for use in wireless networks.
Figure: Flow Diagram of CSMA/CA

7) Illustrate the frame structure of IEEE 802.11


 IEEE has defined the specifications for a wireless LAN, called IEEE 802.11, which
covers the physical and data link layers.
 Architecture:
 The standard defines two kinds of services:
The Basic Service Set (BSS) and The extended service set (ESS).
 Basic Service Set
o IEEE 802.11 defines the basic service set (BSS) as the building block of a
wireless LAN.
o A basic service set is made of stationary or mobile wireless stations and an
optional central base station, known as the access point (AP).
o The BSS without an AP is a stand-alone network and cannot send data to
other BSSs. It is called an ad hoc architecture. In this architecture, stations
can form a network without the need of an AP; they can locate one another
and agree to be part of a BSS.
o A BSS with an AP is sometimes referred to as an infrastructure network.

Figure: BSS with AP and Without AP


 Extended Service Set:
o An extended service set (ESS) is made up of two or more BSSs with APs.
In this case, the BSSs are connected through a distribution system, which is
usually a wired LAN.
o The distribution system connects the APs in the BSSs.
o IEEE 802.11 does not restrict the distribution system; it can be any IEEE
LAN such as an Ethernet.
o The extended service set uses two types of stations: mobile and stationary.
o The mobile stations are normal stations inside a BSS.
o The stationary stations are AP stations that are part of a wired LAN.
o When BSSs are connected, the stations within reach of one another can
communicate without the use of an AP. Communication between two
stations in two different BSSs usually occurs via two APs.
o The idea is similar to communication in a cellular network if we consider
each BSS to be a cell and each AP to be a base station.
o A mobile station can belong to more than one BSS at the same time.

Figure: Extended Service Set.


 Frame Format:

o Frame control (FC): The FC field is 2 bytes long and defines the type of
frame and some control information.
The Subfields of FC:

o Addresses: There are four address fields, each 6 bytes long. The meaning
of each address field depends on the value of the To DS and From DS
subfields.

o Sequence control: This field defines the sequence number of the frame to
be used in flow control.
o Frame body: This field, which can be between 0 and 2312 bytes, contains
information based on the type and the subtype defined in the FC field.
o FCS: The FCS field is 4 bytes long and contains a CRC-32 error detection
sequence.
 Frame Types
o A wireless LAN defined by IEEE 802.11 has three categories of frames:
management frames, control frames, and data frames.
o Management Frames: Management frames are used for the initial
communication between stations and access points.
o Control Frames: Control frames are used for accessing the channel and
acknowledging frames.

o Data Frames: Data frames are used for carrying data and control
information.
 Hidden Station Problem:

Figure: Hidden Station Problem


o Figure shows an example of the hidden station problem.
o Station B has a transmission range shown by the left oval (sphere in space);
every station in this range can hear any signal transmitted by station B.
o Station C has a transmission range shown by the right oval (sphere in space);
every station located in this range can hear any signal transmitted by C.
o Station C is outside the transmission range of B; likewise, station B is
outside the transmission range of C.
o Station A, is in the area covered by both Band C; it can hear any signal
transmitted by B or C.
o Assume that station B is sending data to station A. In the middle of this
transmission, station C also has data to send to station A. Station C is out of
B's range and transmissions from B cannot reach C. Therefore C thinks the
medium is free.
o Station C sends its data to A, which results in a collision at A because this
station is receiving data from both B and C.
o In this case, we say that stations Band C are hidden from each other with
respect to A.
o Hidden stations can reduce the capacity of the network because of the
possibility of collision.
o Solution:
 Hidden Station Problem can be solved using the handshake frames
(RTS and CTS).

Figure: Use of handshaking to prevent hidden station problem

 Figure shows that the RTS message from B reaches A, but not C.
 Because both Band C are within the range of A, the CTS message,
which contains the duration of data transmission from B to Areaches
C.
 Station C knows that some hidden station is using the channel and
refrains from transmitting until that duration is over.
 Exposed Station Problem:
o In this problem a station refrains from using a channel when it is, available.
o In Figure, station A is transmitting to station B.
o Station C has some data to send to station D, which can be sent without
interfering with the transmission from A to B.
o Station C is exposed to transmission from A; it hears what A is sending and
thus refrains from sending. In other words, C is too conservative and wastes
the capacity of the channel.
Figure: Exposed Station Problem
o Solution:
 The handshaking messages RTS and CTS cannot help in this case,
despite what you might think.
 Station C hears the RTS from A, but does not hear the CTS from B.
Station C, after hearing the RTS from A, can wait for a time so that
the CTS from B reaches A; it then sends an RTS to D to show that
it needs to communicate with D. Both stations B and A may hear
this RTS, but station A is in the sending state, not the receiving state.
 Station B, responds with a CTS. The problem is here. If station A
has started sending its data, station C cannot hear the CTS from
station D because of the collision; it cannot send its data to D.
 It remains exposed until A finishes sending its data.

Figure: Use of handshaking in exposed station


UNIT-3
Short questions and answers

1.What are the main functions performed by the network layer?

Ans: Routing, Logical Addressing, Internetworking, Fragmentation

2.What are the Services Provided by the Network Layer?

Ans: Guaranteed delivery, Guaranteed delivery with bounded delay, In-Order packets, Guaranteed
max jitter.

3. How many parts an IP Address is divided?

Ans: An ip address is divided into two parts:

o Network ID: It represents the number of networks.

o Host ID: It represents the number of hosts.

4.What is Routing?

Ans: A Router is a process of selecting path along which the data can be transferred from source to the
destination. Routing is performed by a special device known as a router.
5. Types of Routing?

Ans: Routing can be classified into three categories:

o Static Routing

o Default Routing

o Dynamic Routing

6. Default Routing?

Ans: Default Routing is a technique in which a router is configured to send all the packets to the same
hop device, and it doesn't matter whether it belongs to a particular network or not. A Packet is
transmitted to the device for which it is configured in default routing.

7.What is ARP?

Ans: ARP stands for Address Resolution Protocol.

o It is used to associate an IP address with the MAC address.

8.What is RARP?

Ans: RARP stands for Reverse Address Resolution Protocol.


o If the host wants to know its IP address, then it broadcast the RARP query packet that contains
its physical address to the entire network. A RARP server on the network recognizes the RARP
packet and responds back with the host IP address.
o The protocol which is used to obtain the IP address from a server is known as Reverse Address
Resolution Protocol.

9. What is ICMP?

Ans: ICMP stands for Internet Control Message Protocol.

o The ICMP is a network layer protocol used by hosts and routers to send the notifications of IP
datagram problems back to the sender.

o ICMP uses echo test/reply to check whether the destination is reachable and responding.

o ICMP handles both control and error messages, but its main function is to report the error but
not to correct them.

10. What is Error Reporting?

Ans: ICMP protocol reports the error messages to the sender.

Five types of errors are handled by the ICMP protocol:

o Destination unreachable

o Source Quench

o Time Exceeded

o Parameter problems

o Redirection

11. What is IGMP?

Ans: IGMP stands for Internet Group Message Protocol.

o The IP protocol supports two types of communication:


o Unicasting: It is a communication between one sender and one receiver. Therefore, we
can say that it is one-to-one communication.

o Multicasting: Sometimes the sender wants to send the same message to a large
number of receivers simultaneously. This process is known as multicasting which has
one-to-many communication.
1. Explain the design issues of the Network layer.

NETWORK LAYER DESIGN ISSUES


Store-and-Forward Packet Switching
 The major components of the system are the Subnet (routers connected by
transmission lines), and the Hosts.

 Host H1 is directly connected to one of the carrier's routers, A, by a leased line. In


contrast, H2 is on a LAN with a router, F, owned and operated by the customer. This
router also has a leased line to the carrier's equipment.
 We have shown F as being outside the oval because it does not belong to the carrier,
but in terms of construction, software, and protocols, it is probably no different from
the carrier's routers.
 A host with a packet to send transmits it to the nearest router, either on its own LAN
or over a point-to-point link to the carrier. The packet is stored there until it has fully
arrived so the checksum can be verified.
 Then it is forwarded to the next router along the path until it reaches the destination
host, where it is delivered. This mechanism is store-and-forward packet switching.
Implementation of Connectionless Service (Datagram Switching Subnet)
 If connectionless service is offered, packets are injected into the subnet individually
and routed independently of each other.
 No advance setup is needed.
 The packets are frequently called datagrams (in analogy with telegrams) and the
subnet is called a datagram subnet.
 If connection-oriented service is used, a path from the source router to the
destination router must be established before any data packets can be sent. This
connection is called a VC (virtual circuit), in analogy with the physical circuits set up by
the telephone system, and the subnet is called a virtual-circuit subnet.
 Let us now see how a datagram subnet works. Suppose that the process P1 in the
above figure, has a long message for P2. It hands the message to the transport layer
with instructions to deliver it to process P2 on host H2. The transport layer code runs
on H1, typically within the operating system. It prepends a transport header to the
front of the message and hands the result to the network layer, probably just another
procedure within the operating system.
 Let us assume that the message is four times longer than the maximum packet size,
so the network layer has to break it into four packets, 1, 2, 3, and 4 and sends each of
them in turn to router A using some point-to-point protocol, for example, PPP.
 Every router has an internal table telling it where to send packets for each possible
destination.
 Each table entry is a pair consisting of a destination and the outgoing line to use for
that destination. Only directly-connected lines can be used.
 For example, in the figure, A has only two outgoing lines—to B and C—so every
incoming packet must be sent to one of these routers, even if the ultimate destination
is some other router. A's initial routing table is shown in the figure under the label
''initially.''
 As they arrived at A, packets 1, 2, and 3 were stored briefly (to verify their
checksums). Then each was forwarded to C according to A's table. Packet 1 was then
forwarded to E and then to F. When it got to F, it was encapsulated in a data link layer
frame and sent to H2 over the LAN. Packets 2 and 3 follow the same route.
 However, something different happened to packet 4. When it got to A it was sent to
router B, even though it is also destined for F. For some reason, A decided to send
packet 4 via a different route than that of the first three.
 Perhaps it learned of a traffic jam somewhere along the ACE path and updated its
routing table, as shown under the label ''later.''
 The algorithm that manages the tables and makes the routing decisions is called the
routing algorithm. Implementation of Connection-Oriented Service (Virtual Circuit
Switching Subnet)
 For connection-oriented service, we need a virtual-circuit subnet.
 The idea behind virtual circuits is to avoid having to choose a new route for every
packet sent. Instead, when a connection is established, a route from the source
machine to the destination machine is chosen as part of the connection setup and
stored in tables inside the routers.
 That route is used for all traffic flowing over the connection, exactly the same way
that the telephone system works.
 When the connection is released, the virtual circuit is also terminated. With
connection-oriented service, each packet carries an identifier telling which virtual
circuit it belongs to.

 As an example, consider the above figure, Here, host H1 has established connection
1 with host H2. It is remembered as the first entry in each of the routing tables.
 The first line of A's table says that if a packet bearing connection identifier 1 comes
in from H1, it is to be sent to router C and given connection identifier 1.
 Similarly, the first entry at C routes the packet to E, also with connection identifier 1.
 Now let us consider what happens if H3 also wants to establish a connection to H2.
It chooses connection identifier 1 (because it is initiating the connection and this is its
only connection) and tells the subnet to establish the virtual circuit. This leads to the
second row in the tables.
 Note that we have a conflict here because although A can easily distinguish
connection 1 packets from H1 from connection 1 packets from H3, C cannot do this.
For this reason, A assigns a different connection identifier to the outgoing traffic for
the second connection. Avoiding conflicts of this kind is why routers need the ability
to replace connection identifiers in outgoing packets.
 In some contexts, this is called label switching. Services Provided to the Transport
Layer
 The network layer provides services to the transport layer at the network
layer/transport layer interface.
 The network layer services have been designed with the following goals in mind. o
The services should be independent of the router technology. o The transport layer
should be shielded from the number, type, and topology of the routers present. o The
network addresses made available to the transport layer should use a uniform
numbering plan, even across LANs and WANs.
2. Discuss about different routing algorithms in detail

ROUTING ALGORITHMS
 The main function of the network layer is routing packets from the source machine to the
destination machine.
 In most subnets, packets will require multiple hops to make the journey. The only notable
exception is for broadcast networks, but even here routing is an issue if the source and
destination are not on the same network.
 The algorithms that choose the routes and the data structures that they use are a major area
of network layer design.
 The routing algorithm is that part of the network layer software responsible for deciding
which output line an incoming packet should be transmitted on.
 If the subnet uses datagrams internally, this decision must be made anew for every arriving
data packet since the best route may have changed since last time.
 If the subnet uses virtual circuits internally, routing decisions are made only when a new
virtual circuit is being set up. Thereafter, data packets just follow the previouslyestablished
route. This is sometimes called session routing because a route remains in force for an entire
user session.
 Router perform two tasks o Routing: Making the decision which routes to use. o Forwarding:
Looking up the outgoing line to use for it in the routing tables.
 Properties of routing algorithms:
o Correctness
o Simplicity o Robustness
o Stability
o Fairness, and
o Optimality
 Routing algorithms can be grouped into two major classes:
1. Non-adaptive Algorithms : Static and offline. They will not work if there is any failure of link
or modification of the subnet. Here the path is calculated prior to the data transmission. Non-
adaptive algorithms do not base their routing decisions on measurements or estimates of the
current traffic and topology. This procedure is sometimes called static routing. Examples:
Shortest path routing and Flooding
2. Adaptive algorithms: Dynamic and online. These algorithms change their routing decisions
to reflect changes in the topology, and usually the traffic as well. Adaptive algorithms differ in
where they get their information (e.g., locally, from adjacent routers, or from all routers),
when they change the routes (e.g., every T sec, when the load changes or when the topology
changes), and what metric is used for optimization (e.g., distance, number of hops, or
estimated transit time).
 Optimality principle: It states that if router J is on the optimal path from router I to router K,
then the optimal path from J to K also falls along the same route.

3. Describe Dijkstra shortest path algorithm. Also show working of Dijkstra algorithm with
the help of an example.

Shortest Path Routing


 The subnet is considered as a graph, with each node of the graph representing a router and
each arc of the graph representing a communication line (often called a link).
 To choose a route between a given pair of routers, the algorithm just finds the shortest path
between them on the graph. One way of measuring path length is the number of hops.
Another metric is the geographic distance in kilometres.
 The labels on the arcs could be computed as a function of the distance, bandwidth, average
traffic, communication cost, mean queue length, measured delay, and other factors. By
changing the weighting function, the algorithm would then compute the ''shortest'' path
measured according to any one of a number of criteria or to a combination of criteria.
 Dijkstra's algorithm is a shortest path routing algorithm in which the shortest path is
measured from single source to all destinations in the subnet graph.
 Each node is labelled (in parentheses) with its distance from the source node along the best
known path. Initially, no paths are known, so all nodes are labelled with infinity. As the
algorithm proceeds and paths are found, the labels may change, reflecting better paths. A
label may be either tentative or permanent. Initially, all labels are tentative. When it is
discovered that a label represents the shortest possible path from the source to that node, it
is made permanent and never changed thereafter.

ALGORITHM:
Dijkstra's Let the node at which we are starting be called the initial node. Let the distance of
node Y be the distance from the initial node to Y. Dijkstra's algorithm will assign some initial
distance values and will try to improve them step by step.
1. Assign to every node a tentative distance value: set it to zero for our initial node and to
infinity for all other nodes.
2. Mark all nodes unvisited. Set the initial node as current. Create a set of the unvisited nodes
called the unvisited set consisting of all the nodes except the initial node.
3. For the current node, consider all of its unvisited neighbours and calculate their tentative
distances. For example, if the current node A is marked with a distance of 6, and the edge
connecting it with a neighbor B has length 2, then the distance to B (through A) will be 6+2=8.
If this distance is less than the previously recorded tentative distance of B, then overwrite that
distance. Even though a neighbor has been examined, it is not marked as "visited" at this time,
and it remains in the unvisited set.
4. When we are done considering all of the neighbors of the current node, mark the current
node as visited and remove it from the unvisited set. A visited node will never be checked
again.
5. If the destination node has been marked visited (when planning a route between two
specific nodes) or if the smallest tentative distance among the nodes in the unvisited set is
infinity (when planning a complete traversal), then stop. The algorithm has finished.
6. Select the unvisited node that is marked with the smallest tentative distance, and set it as
the new "current node" then go back to step 3.

Example:
4. Explain distance vector routing algorithm

Distance Vector Routing.


 Distance vector routing algorithms operate by having each router maintain a table (i.e, a
vector) giving the best known distance to each destination and which line to use to get there.
These tables are updated by exchanging information with the neighbours.
 The distance vector routing algorithm is sometimes called Bellman-Ford routing algorithm
and the Ford-Fulkerson algorithm, after the researchers who developed it (Bellman, 1957; and
Ford and Fulkerson, 1962).
 It was the original ARPANET routing algorithm and was also used in the Internet under the
name RIP.
 In distance vector routing, each router maintains a routing table indexed by, and containing
one entry for, each router in the subnet.
 This entry contains two parts: the preferred outgoing line to use for that destination and an
estimate of the time or distance to that destination.
 The metric used might be number of hops, time delay in milliseconds, total number of
packets queued along the path, or something similar.
 The router is assumed to know the ''distance'' to each of its neighbours.
 If the metric is hops, the distance is just one hop.
 If the metric is queue length, the router simply examines each queue.
 If the metric is delay, the router can measure it directly with special ECHO packets that the
receiver just timestamps and sends back as fast as it can.
EXAMPLE:
 As an example, assume that delay is used as a metric and that the router knows the delay to
each of its neighbours.
 Once every T msec each router sends to each neighbour a list of its estimated delays to each
destination. It also receives a similar list from each neighbour.
 Imagine that one of these tables has just come in from neighbour X, with Xi being X's
estimate of how long it takes to get to router i. If the router knows that the delay to X is m
msec, it also knows that it can reach router i via X in Xi + m msec. By performing this calculation
for each neighbour, a router can find out which estimate seems the best and use that estimate
and the corresponding line in its new routing table. Note that the old routing table is not used
in the calculation.

 This updating process is illustrated in the above figure. Part (a) shows a subnet. The first four
columns of part (b) show the delay vectors received from the neighbours of router J.
 A claims to have a 12-msec delay to B, a 25-msec delay to C, a 40-msec delay to D, etc.
Suppose that J has measured or estimated its delay to its neighbors, A, I, H, and K as 8, 10, 12,
and 6 msec, respectively.
 Consider how J computes its new route to router G. It knows that it can get to A in 8 msec,
and A claims to be able to get to G in 18 msec, so J knows it can count on a delay of 26 msec
to G if it forwards packets bound for G to A. Similarly, it computes the delay to G via I, H, and
K as 41 (31 + 10), 18 (6 + 12), and 37 (31 + 6) msec, respectively. The best of these values is
18, so it makes an entry in its routing table that the delay to G is 18 msec and that the route
to use is via H. The same calculation is performed for all the other destinations, with the new
routing table shown in the last column of the figure.

5. Explain in detail about Congestion Control Algorithms.

CONGESTION CONTROL ALGORITHMS


Congestion: When too many packets are present in the subnet, performance degrades. This
situation is called congestion.
 The above figure depicts the symptom.
o When the number of packets dumped into the subnet by the hosts is within its
carrying capacity, they are all delivered (except for a few that are afflicted with transmission
errors) and the number delivered is proportional to the number sent.
o However, as traffic increases too far, the routers are no longer able to cope and they
begin losing packets. This tends to make matters worse.
o At very high trafffic, performance collapses completely and almost no packets are
delivered.
 Congestion can be caused by several factors.
o If all of a sudden, streams of packets begin arriving on three or four input lines and all
need the same output line, a queue will build up.
o If there is insufficient memory to hold all of them, packets will be lost.
o Slow processors can also cause congestion. If the routers' CPUs are slow at
performing the bookkeeping tasks required of them (queuing buffers, updating tables, etc.),
queues can build up, even though there is excess line capacity.
o Low-bandwidth lines can also cause congestion. Upgrading the lines but not changing
the processors, or vice versa, often helps a little, but frequently just shifts the bottleneck.
 The metrics to monitor the subnet for congestion.
 The percentage of all packets discarded for lack of buffer space
 The average queue lengths
 The number of packets that time out and are retransmitted,
 The average packet delay, and the standard deviation of packet delay. In all cases, rising
numbers indicate growing congestion.

6. Explain briefly about Flooding.

Flooding
 In this, every incoming packet is sent out on every outgoing line except the one it arrived on.
 Flooding obviously generates vast numbers of duplicate packets, in fact, an infinite number
unless some measures are taken to damp the process.
 One such measure is to have a hop counter contained in the header of each packet, which
is decremented at each hop, with the packet being discarded when the counter reaches zero.
 Ideally, the hop counter should be initialized to the length of the path from source to
destination.
 If the sender does not know how long the path is, it can initialize the counter to the worst
case, namely, the full diameter of the subnet.
 An alternative technique for damming the flood is to keep track of which packets have been
flooded, to avoid sending them out a second time. achieve this goal is to have the source
router put a sequence number in each packet it receives from its hosts. Each router then needs
a list per source router telling which sequence numbers originating at that source have already
been seen. If an incoming packet is on the list, it is not flooded.
 Selective flooding is the variant of flooding. In this algorithm the routers do not send every
incoming packet out on every line, only on those lines that are going approximately in the
right direction.
 Flooding is used in military applications, distributed database applications.
 Flooding always chooses the shortest path because it chooses every possible path in parallel.

7. With an example, explain shortest path routing.

Shortest Path Routing


 The subnet is considered as a graph, with each node of the graph representing a router and
each arc of the graph representing a communication line (often called a link).
 To choose a route between a given pair of routers, the algorithm just finds the shortest path
between them on the graph. One way of measuring path length is the number of hops.
Another metric is the geographic distance in kilometres.
 The labels on the arcs could be computed as a function of the distance, bandwidth, average
traffic, communication cost, mean queue length, measured delay, and other factors. By
changing the weighting function, the algorithm would then compute the ''shortest'' path
measured according to any one of a number of criteria or to a combination of criteria.
 Dijkstra's algorithm is a shortest path routing algorithm in which the shortest path is
measured from single source to all destinations in the subnet graph.
 Each node is labelled (in parentheses) with its distance from the source node along the best
known path. Initially, no paths are known, so all nodes are labelled with infinity. As the
algorithm proceeds and paths are found, the labels may change, reflecting better paths. A
label may be either tentative or permanent. Initially, all labels are tentative. When it is
discovered that a label represents the shortest possible path from the source to that node, it
is made permanent and never changed thereafter.

8. Explain about QOS in network layer

Quality-of-service (QoS) refers to traffic control mechanisms that seek to differentiate


performance based on application or network-operator requirements or provide predictable
or guaranteed performance to applications, sessions, or traffic aggregates. The basic
phenomenon for QoS is in terms of packet delay and losses of various kinds.

QoS Specification
 Delay
 Delay Variation(Jitter)
 Throughput
 Error Rate

Types of Quality of Service


 Stateless Solutions – Routers maintain no fine-grained state about traffic, one positive
factor of it is that it is scalable and robust. But it has weak services as there is no
guarantee about the kind of delay or performance in a particular application which we
have to encounter.
 Stateful Solutions – Routers maintain a per-flow state as flow is very important in
providing the Quality-of-Service i.e. providing powerful services such as guaranteed
services and high resource utilization, providing protection, and is much less scalable
and robust.

Models to Implement QoS


1. Integrated Services (IntServ)
 An architecture for providing QoS guarantees in IP networks for individual application
sessions.
 Relies on resource reservation, and routers need to maintain state information of
allocated resources and respond to new call setup requests.
 Network decides whether to admit or deny a new call setup request.
2. IntServ QoS Components
 Resource reservation: call setup signaling, traffic, QoS declaration, per-element
admission control.
 QoS-sensitive scheduling e.g WFQ queue discipline.
 QoS-sensitive routing algorithm(QSPF)
 QoS-sensitive packet discard strategy.
3. RSVP-Internet Signaling
It creates and maintains distributed reservation state, initiated by the receiver and scales for
multicast, which needs to be refreshed otherwise reservation times out as it is in soft state.
Latest paths were discovered through “PATH” messages (forward direction) and used by RESV
messages (reserve direction).
4. Call Admission
 Session must first declare it’s QoS requirement and characterize the traffic it will send
through the network.
 R-specification: defines the QoS being requested, i.e. what kind of bound we want on
the delay, what kind of packet loss is acceptable, etc.
 T-specification: defines the traffic characteristics like bustiness in the traffic.
 A signaling protocol is needed to carry the R-spec and T-spec to the routers where
reservation is required.
 Routers will admit calls based on their R-spec, T-spec and based on the current
resource allocated at the routers to other calls.
5. Diff-Serv
Differentiated Service is a stateful solution in which each flow doesn’t mean a different state.
It provides reduced state services i.e. maintaining state only for larger granular flows rather
than end-to-end flows tries to achieve the best of both worlds. Intended to address the
following difficulties with IntServ and RSVP:
 Flexible Service Models: IntServ has only two classes, want to provide more qualitative
service classes: want to provide ‘relative’ service distinction.
 Simpler signaling: Many applications and users may only want to specify a more
qualitative notion of service.

9. Explain about internetworking. IPV4 AND IPV6

IPv4
IPv4 addresses consist of two things: the network address and the host address. It stands
for Internet Protocol version four. It was introduced in 1981 by DARPA and was the first
deployed version in 1982 for production on SATNET and on the ARPANET in January 1983.
IPv4 addresses are 32-bit integers that have to be expressed in Decimal Notation. It is
represented by 4 numbers separated by dots in the range of 0-255, which have to be
converted to 0 and 1, to be understood by Computers. For Example, An IPv4 Address can be
written as 189.123.123.90.

IPv4 Address Format


IPv4 Address Format is a 32-bit Address that comprises binary digits separated by a dot (.).
Drawback of IPv4
 Limited Address Space : IPv4 has a limited number of addresses, which is not enough
for the growing number of devices connecting to the internet.
 Complex Configuration : IPv4 often requires manual configuration or DHCP to assign
addresses, which can be time-consuming and prone to errors.
 Less Efficient Routing : The IPv4 header is more complex, which can slow down data
processing and routing.
 Security Issues : IPv4 does not have built-in security features, making it more
vulnerable to attacks unless extra security measures are added.
 Limited Support for Quality of Service (QoS) : IPv4 has limited capabilities for
prioritizing certain types of data, which can affect the performance of real-time
applications like video streaming and VoIP.
 Fragmentation : IPv4 allows routers to fragment packets, which can lead to
inefficiencies and increased chances of data being lost or corrupted.
 Broadcasting Overhead : IPv4 uses broadcasting to communicate with multiple
devices on a network, which can create unnecessary network traffic and reduce
performance.

What is IPv6?
IPv6 is based on IPv4 and stands for Internet Protocol version 6. It was first introduced in
December 1995 by Internet Engineering Task Force. IP version 6 is the new version of Internet
Protocol, which is way better than IP version 4 in terms of complexity and efficiency. IPv6 is
written as a group of 8 hexadecimal numbers separated by colon (:). It can be written as 128
bits of 0s and 1s.
IPv6 Address Format
IPv6 Address Format is a 128-bit IP Address, which is written in a group of 8 hexadecimal
numbers separated by colon (:).

To switch from IPv4 to IPv6, there are several strategies:


 Dual Stacking : Devices can use both IPv4 and IPv6 at the same time. This way, they
can talk to networks and devices using either version.
 Tunneling : This method allows IPv6 users to send data through an IPv4 network to
reach other IPv6 users. Think of it as creating a “tunnel” for IPv6 traffic through the
older IPv4 system.
 Network Address Translation (NAT) : NAT helps devices using different versions of IP
addresses (IPv4 and IPv6) to communicate with each other by translating the
addresses so they understand each other.
Difference Between IPv4 and IPv6
IPv4 IPv6

IPv4 has a 32-bit address length IPv6 has a 128-bit address length

It Supports Manual It supports Auto and renumbering address


and DHCP address configuration configuration

In IPv4 end to end, connection In IPv6 end-to-end, connection integrity is


integrity is Unachievable Achievable

It can generate 4.29×10 9 address The address space of IPv6 is quite large it can
space produce 3.4×10 38 address space

The Security feature is dependent IPSEC is an inbuilt security feature in the IPv6
on the application protocol

Address representation of IPv4 is in


Address representation of IPv6 is in hexadecimal
decimal

Fragmentation performed by In IPv6 fragmentation is performed only by the


Sender and forwarding routers sender

In IPv4 Packet flow identification is In IPv6 packet flow identification are Available and
not available uses the flow label field in the header

In IPv4 checksum field is available In IPv6 checksum field is not available

It has a broadcast Message In IPv6 multicast and anycast message transmission


Transmission Scheme scheme is available

In IPv4 Encryption and


In IPv6 Encryption and Authentication are provided
Authentication facility not provided

IPv4 has a header of 20-60 bytes. IPv6 has a header of 40 bytes fixed

IPv4 can be converted to IPv6 Not all IPv6 can be converted to IPv4

IPv4 consists of 4 fields which are IPv6 consists of 8 fields, which are separated by a
separated by addresses dot (.) colon (:)
IPv4 IPv6

IPv4’s IP addresses are divided into


five different classes. Class A , Class IPv6 does not have any classes of the IP address.
B, Class C, Class D , Class E.

IPv4 supports VLSM( Variable


IPv6 does not support VLSM.
Length subnet mask ).

Example of IPv6:
Example of IPv4: 66.94.29.13
2001:0000:3238:DFE1:0063:0000:0000:FEFB

10. Explain about Link state routing algorithm

Link State Routing


 Distance vector routing was used in the ARPANET until 1979, when it was replaced by link
state routing.
 Two primary problems caused by Distance Vector Routing are o First, since the delay metric
was queue length, it did not take line bandwidth into account when choosing routes. o Count-
to-Infinity problem.
 For these reasons, it was replaced by an entirely new algorithm, now called link state routing.
Variants of link state routing are now widely used.
 The idea behind link state routing is simple and can be stated as five parts. Each router must
do the following:
1. Discover its neighbours and learn their network addresses.
2. Measure the delay or cost to each of its neighbours.
3. Construct a packet telling all it has just learned.
4. Send this packet to all other routers.
5. Compute the shortest path to every other router.
 Learning about the Neighbours o When a router is booted, its first task is to learn who its
neighbours are.
o It accomplishes this goal by sending a special HELLO packet on each point-to-point line.
o The router on the other end is expected to send back a reply telling who it is. These names
must be globally unique because when a distant router later hears that three routers are all
connected to F, it is essential that it can determine whether all three mean the same F.
o When two or more routers are connected by a LAN, the situation is slightly more
complicated. figure (a) illustrates a LAN to which three routers, A, C, and F, are directly
connected. Each of these routers is connected to one or more additional routers, as shown.
o One way to model the LAN is to consider it as a node itself, as shown in figure (b). Here we
have introduced a new, artificial node, N, to which A, C, and F are connected. The fact that it
is possible to go from A to C on the LAN is represented by the path ANC here.

 Measuring Line Cost


o The link state routing algorithm requires each router to know, or at least have a
reasonable estimate of, the delay to each of its neighbours.
o The most direct way to determine this delay is to send over the line a special ECHO
packet that the other side is required to send back immediately.
o By measuring the round-trip time and dividing it by two, the sending router can get a
reasonable estimate of the delay.
o For even better results, the test can be conducted several times, and the average used.

 Building Link State Packets


o The link state packet carries the information: the node identity, the list of links, a
sequence number, and age. The first two, node identity and the list of links, are needed to
make the topology. The third, sequence number, facilitates flooding and distinguishes new
LSPs from old ones. The fourth, age, prevents old LSPs from remaining in the domain for a long
time.

o LSPs are generated on two occasions:


1. When there is a change in the topology of the domain. Triggering of LSP dissemination is
the main way of quickly informing any node in the domain to update its topology.
2. On a periodic basis. The period in this case is much longer compared to distance vector
routing. It is done to ensure that old information is removed from the domain. The timer set
for periodic dissemination is normally in the range of 60 min or 2 h based on the
implementation. A longer period ensures that flooding does not create too much traffic on
the network.

 Distributing the Link State Packets


o The trickiest part of the algorithm is distributing the link state packets reliably. As the
packets are distributed and installed, the routers getting the first ones will change their routes.
Consequently, the different routers may be using different versions of the topology, which can
lead to inconsistencies, loops, unreachable machines, and other problems.
o The fundamental idea is to use flooding to distribute the link state packets.
o To keep the flood in check, each packet contains a sequence number that is incremented
for each new packet sent. Routers keep track of all the (source router, sequence) pairs they
see.
o When a new link state packet comes in, it is checked against the list of packets already
seen.
 If it is new, it is forwarded on all lines except the one it arrived on.
 If it is a duplicate, it is discarded.
 If a packet with a sequence number lower than the highest one seen so far ever arrives,
it is rejected as being obsolete since the router has more recent data.

o Problem and solution for flooding:


 If the sequence numbers wrap around, confusion will reign. The solution here is to use
a 32-bit sequence number. With one link state packet per second, it would take 137 years to
wrap around, so this possibility can be ignored.
 If a router ever crashes, it will lose track of its sequence number. If it starts again at 0,
the next packet will be rejected as a duplicate.
 If a sequence number is ever corrupted and 65,540 is received instead of 4 (a 1-bit error),
packets 5 through 65,540 will be rejected as obsolete, since the current sequence number is
thought to be 65,540.
o The solution to all these problems is to include the age of each packet after the sequence
number and decrement it once per second.
o When the age hits zero, the information from that router is discarded. Normally, a new
packet comes in, say, every 10 sec, so router information only times out when a router is down
(or six consecutive packets have been lost, an unlikely event). The Age field is also
decremented by each router during the initial flooding process, to make sure no packet can
get lost and live for an indefinite period of time (a packet whose age is zero is discarded).

11. Explain about Hierarichal routing algorithm

Hierarchical Routing
 As networks grow in size, the router routing tables grow proportionally.
 There are some problems with the increase in network size

o Router memory consumed by increasing tables


o CPU time is needed to scan routing table and
o More bandwidth is needed to send status reports about routing table. so the routing
will have to be done hierarchically, as it is in the telephone network.

 When hierarchical routing is used, the routers are divided into regions, with each router
knowing all the details about how to route packets to destinations within its own region, but
knowing nothing about the internal structure of other regions.
 When different networks are interconnected, it is natural to regard each one as a separate
region in order to free the routers in one network from having to know the topological
structure of the other ones.
 For huge networks, a two-level hierarchy may be insufficient; it may be necessary to group
the regions into clusters, the clusters into zones, the zones into groups, and so on, until we
run out of names for aggregations.
Example:
o The below figure (a) gives an example of routing in a two-level hierarchy with five regions.
o The full routing table for router 1A has 17 entries, as shown in Figure (b)
o When routing is done hierarchically, as in Figure (c) there are entries for all the local routers
as before, but all other regions have been condensed into a single router, so all traffic for
region 2 goes via the 1B -2A line, but the rest of the remote traffic goes via the 1C -3B line.
o Hierarchical routing has reduced the table from 17 to 7 entries.
o As the ratio of the number of regions to the number of routers per region grows, the savings
in table space increase.

o For example, consider a subnet with 720 routers. If there is no hierarchy, each router needs
720 routing table entries. If the subnet is partitioned into 24 regions of 30 routers each, each
router needs 30 local entries plus 23 remote entries for a total of 53 entries. If a three-level
hierarchy is chosen, with eight clusters, each containing 9 regions of 10 routers, each router
needs 10 entries for local routers, 8 entries for routing to other regions within its own cluster,
and 7 entries for distant clusters, for a total of 25 entries.
o Kamoun and Kleinrock (1979) discovered that the optimal number of levels for an N router
subnet is ln N, requiring a total of e ln N entries per router.
o They have also shown that the increase in effective mean path length caused by hierarchical
routing is sufficiently small that it is usually acceptable.

12. Write short notes on ICMP,ARP,RARP

ARP (Address Resolution Protocol)


ARP stands for Address Resolution Protocol. ARP is used to convert the logical address ie. IP
address into physical address ie. MAC address. While communicating with other nodes, it is
necessary to know the MAC address or physical address of the destination node. If any of the
node in a network wants to know the physical address of another node in the same network,
the host then sends an ARP query packet. This ARP query packet consists of IP address and
MAC address of source host and only the IP address of destination host. This ARP packet is
then received to every node present in the network. The node with its own IP address
recognises it and sends it MAC address to the requesting node. But sending and receiving such
packets to know the MAC address of destination node it increases the traffic load. Therefore
in order to reduce this traffic and improve the performance, the systems that makes use of
ARP maintain a cache of recently acquired IP into MAC address bindings.

How Does ARP Work?


 The host broadcasts an ARP inquiry packet containing the IP address over the
network in order to find out the physical address of another computer on its
network.
 The ARP packet is received and processed by all hosts on the network; however, only
the intended recipient can identify the IP address and reply with the physical
address.
 After adding the physical address to the datagram header and cache memory, the
host storing the datagram transmits it back to the sender.

Types of ARP Entries


 Static Entry: This type of entry is created when a user uses the ARP command utility
to manually enter the IP to MAC address association.
 Dynamic Entry: A dynamic entry is one that is automatically formed when a sender
broadcasts their message to the whole network. Dynamic entries are periodically
removed and are not permanent.
3. RARP

RARP stands for Reverse Address Resolution Protocol. RARP works opposite of ARP. Reverse
Address Resolution Protocol is used to convert MAC address ie. physical address into IP
address ie. logical address. RARP provides with a feature for the systems and applications to
get their own IP address from a DNS( Domain Name System) or router. This type of
resolution is required for various tasks such as executing reverse DNS lookup. As Reverse
Address Resolution Protocol works at low level it requires direct network addresses. The
reply from the server mostly carries a small information but the 32 bit internet address is
used and it does not exploit the full potential of a network such as ethernet.
How Does RARP Work?

 Data is sent between two places in a network using the RARP, which is on the
Network Access Layer.
 Every user on the network has two distinct addresses: their MAC (physical) address
and their IP (logical) address.
 Software assigns the IP address, and the hardware then builds the MAC address into
the device.
 Any regular computer connected to the network can function as the RARP server,
answering to RARP queries. It must, however, store all of the MAC addresses’
associated IP addresses. Only these RARP servers are able to respond to RARP
requests that are received by the network. The information package must be
transmitted over the network’s lowest tiers.
 Using both its physical address and Ethernet broadcast address, the client transmits
a RARP request. In response, the server gives the client its IP address.
ICMP
ICMP stands for Internet Control Message Protocol. ICMP is a part of IP protocol suite. ICMP
is an error reporting and network diagnostic protocol. Feedback in the network is reported
to the designated host. Meanwhile, if any kind of error occur it is then reported to ICMP.
ICMP protocol consists of many error reporting and diagnostic messages. ICMP protocol
handles various kinds of errors such as time exceeded, redirection, source quench,
destination unreachable, parameter problems etc. The messages in ICMP are divided into
two types. They are given below:

 Error Message: Error message states about the issues or problems that are faced by
the host or routers during processing of IP packet.
 Query Message: Query messages are used by the host in order to get information
from a router or another host.
How Does ICMP Work?
 The main and most significant protocol in the IP suite is called ICMP. However, unlike
TCP and UDP, ICMP is a connectionless protocol, meaning it doesn’t require a
connection to be established with the target device in order to transmit a message.
 TCP and ICMP operate differently from one another; TCP is a connection-oriented
protocol, while ICMP operates without a connection. Every time a connection is
made prior to a message being sent, a TCP Handshake is required of both devices.
 Datagrams including an IP header containing ICMP data are used to transmit ICMP
packets. An independent data item like a packet is comparable to an ICMP datagram.

Dynamic Host Configuration Protocol


Dynamic Host Configuration Protocol (DHCP) is a network management protocol used to
dynamically assign an IP address to nay device, or node, on a network so they can
communicate using IP (Internet Protocol). DHCP automates and centrally manages these
configurations. There is no need to manually assign IP addresses to new devices. Therefore,
there is no requirement for any user configuration to connect to a DHCP based network.
DHCP can be implemented on local networks as well as large enterprise networks. DHCP is
the default protocol used by the most routers and networking equipment. DHCP is also
called RFC (Request for comments) 2131.
DHCP does the following:
o DHCP manages the provision of all the nodes or devices added or dropped from the
network.
o DHCP maintains the unique IP address of the host using a DHCP server.
o It sends a request to the DHCP server whenever a client/node/device, which is
configured to work with DHCP, connects to a network. The server acknowledges by
providing an IP address to the client/node/device.
UNIT - IV

Transport Layer: Transport Services, Elements of Transport protocols,


Connection management, TCP and UDP protocols.
1. What are the duties of the transport layer?

The duties of the transport layer are

a. End (Process) ‐to ‐ end delivery

b. Port Addressing

c. Reliable delivery

d. Flow control

e. Multiplexing

f. Segmentation and Reassembly

2. What are the four aspects related to the reliable delivery of data?

The four aspects related to the reliable delivery of the data


are
a. Error control
b. Sequence control
c. Loss control
d. Duplication control
3. Give any two Transport layer service.

Multiplexing: Transport layer performs multiplexing/de‐ multiplexing


function. Multiple applications employ same transport protocol, but use different
port number. According to lower layer n/w protocol, it does upward
multiplexing or downward multiplexing.

Reliability: Error Control and Flow Control.

4. What is UDP?

User Datagram Protocol (UDP) is a connectionless, unreliable transport


protocol. It does not add anything to the IP services. It provides process‐to‐
process communication and performs limited error checking.
5. What is TCP?

TCP is a connection‐oriented, reliable protocol. It creates a virtual connection


between two TCP’s to send data. TCP uses flow and error control mechanisms
at the transport level
6. List few well known ports for UDP.
Port Protocol Description
7 Echo Echoes a received datagram back to the sender
9 Discard Discards any datagram received
11 Users Active Users
13 Daytime Returns Date and Time

7. Give the datagram format of UDP?

The basic idea of UDP is for a source process to send a message to a port
and for the destination process to receive the message from
a port.
Source Port Address Destination Port Address
16 bits 16 bits

Total Length Checksum


16 bits 16 bits

8. What are the advantages of using UDP over TCP?

UDP is very useful for audio or video delivery which does not need
acknowledgement. It is useful in the transmission of multimedia data. Connection
Establishment delay will occur in TCP.

9. What is the main difference between TCP & UDP?

TCP UDP
It provides connection‐ Provides connectionless service.
oriented service
Connection Establishment No connectionestablishment
delay will be there and no delay
Provides reliable service Provides unreliable, but fast
Service

It is used by FTP, SMTP It is used by DNS, SNMP, audio, video


and multimedia
applications.

10. List the different phases used in TCP Connection.


The different phases used in TCP connection are Connection establishment
Phase, Data transfer and Connection Termination Phase.

11. Draw TCP header format.

12. List the services of TCP from the application program point of
view.
The services of TCP from the application program point of view are
a. Process‐to‐process communication
b. Stream delivery service
c. Sending and receiving buffers
d. Segments
e. Full‐duplex communication.

13. Define Congestion Control?


It involves preventing too much data from being injected into the network,
thereby causing switches or links to become overloaded. Thus flow control is an
end to an end issue, while congestion control is concerned with how hosts and
networks interact.
PART – B
14. Explain in brief about Transport Layer Responsibilities

Transport Layer Responsibilities :


Transport Layer is the second layer of TCP/IP model. It is an end‐to‐end layer used
to deliver messages to a host. It is termed as end‐to‐end layer because it provides a
point‐to‐ point connection rather than hop‐to‐ hop, between the source host and
destination host to deliver the services reliably. The unit of data encapsulation in
Transport Layer is a segment.

The standard protocols used by Transport Layer to enhance it’s functionalities are :

 TCP(Transmission Control Protocol)


 UDP( User Datagram Protocol)
 DCCP( Datagram Congestion Control Protocol) etc.

Various responsibilities of a Transport Layer –


 Process to process delivery –
 End‐to‐end Connection between hosts –
 Multiplexing and De multiplexing –
 Congestion Control –
 Data integrity and Error Correction –
 Flow Control–

1. Process to process delivery :


 Data Link Layer requires the MAC address (48 bits address contained inside
the Network Interface Card of every host machine) of source‐ destination
hosts to correctly deliver a frame and Network layer requires the IP address
for appropriate routing of packets , in a similar way Transport Layer
requires a Port number to correctly deliver the segments of data to the
correct process amongst the multiple processes running on a particular
host.
A port number is a 16 bit address used to identify any client‐server program
uniquely.

2. End-to-end Connection between hosts :–


 Transport layer is also responsible for creating the end‐to‐end Connection
between hosts for which it mainly uses TCP and UDP.
 TCP is a secure, connection‐ orientated protocol which uses a handshake
protocol to establish a robust connection between two end‐ hosts.

3. Multiplexing and De multiplexing –


 Multiplexing allows simultaneous use of different applications over a
network which are running on a host.
 Transport layer provides this mechanism which enables us to send packet
streams from various applications simultaneously over a network.

4. Congestion Control :–
Congestion is a situation in which too many sources over a network attempt to send
data and the router buffers start overflowing due to which loss of packets occur.
 As a result retransmission of packets from the sources increase the
congestion further.
 In this situation Transport layer provides Congestion Control in different
ways.
 It uses open loop congestion control (Retransmission Policy , Window
Policy , Acknowledgment Policy etc..) to prevent the congestion and
closed loop congestion(Backpressure , Choke Packet Technique etc..)
control to remove the congestion in a network once it occurred.
 TCP provides AIMD‐ Additive Increase Multiplicative Decrease,
 Leaky bucket technique for congestion control.
5. Data integrity and Error Correction
Transport layer checks for errors in the messages coming from application layer by
using error detection codes, computing checksums, it checks whether the received data
is not corrupted and uses the ACK and NACK services to inform the sender if the data is
arrived or not and checks for the integrity of data.
6. Flow control :–
 Transport layer provides a flow control mechanism between the adjacent
layers of the TCP/IP model.
 TCP also prevents the data loss due to a fast sender and slow receiver by
imposing some flow control techniques.
 It uses the method of sliding window protocol which is accomplished
by receiver by sending a window back to the sender informing the size of
data it can receive.

15. Explain in brief about TCP connection establishment and Release.


With packet lifetimes bounded, it is possible to devise a fool proof way to establish
connections safely.
Packet lifetime can be bounded to a known maximum using one of the following
techniques:
 Restricted subnet design
 Putting a hop counter in each packet
 Time stamping in each packet
Using a 3‐way hand shake, a connection can be established. This establishment
protocol doesn’t require both sides to begin sending with the same sequence number.
Fig 4.6: Three protocol scenarios for establishing a connection using a three-way
handshake. CR denotes CONNEC TION REQUEST (a) Normal operation. (b) Old duplicate
CONNECTION REQUEST appearing out of nowhere. (c) Duplicate

CONNECTION REQUEST and duplicate ACK .

In fig (A) Tomlinson (1975) introduced the three-way handshake.

 This establishment protocol involves one peer checking with the other that
the connection request is indeed current. Host 1 chooses a sequence
number, x , and sends a CONNECTION REQUEST segment containing it to
host 2. Host 2 replies with an ACK segment acknowledging x and
announcing its own initial sequence number, y.
 Finally, host 1 acknowledges host 2’s choice of an initial sequence number in
the first data segment that it sends

In fig (B) the first segment is a delayed duplicate CONNECTION REQUEST from
an old connection.
 This segment arrives at host 2 without host 1’s knowledge. Host 2 reacts to
this segment by sending host1an ACK segment, in effect asking for
verification thathost 1 was indeed trying to set up a new connection.

 When host 1 rejects host 2’s attempt to establish a connection, host 2


realizes that it was tricked by a delayed duplicate and abandons the
connection. In this way, a delayed duplicate does no damage.

 The worst case is when both a delayed CONNECTION REQUEST and an ACK
are floating around in the subnet.

In fig (C) previous example, host 2 gets a delayed CONNECTION REQUEST and
replies to it.
 At this point, it is crucial to realize that host 2 has proposed using y as the
initial sequence number for host 2 to host 1 traffic, knowing full well that no
segments containing sequence number y or acknowledgements to y are still
Fig‐(a) Fig‐(b) Fig‐(c) Fig‐(d)
One of the user sends a Initial process is done
If the second DR is Same as in fig‐(
DISCONNECTION lost,
in the same way as in the user c) except that all
REQUEST TPDU in fig‐(a). initiating the repeated attempts
order to initiate connection disconnection will not
If the final ACK‐TPDU to retransmit the
receive the expected
release. is lost, the situation is DR is assumed to
response, and will
When it arrives, the saved by the timer. timeout and starts all be failed due to
recipient over again.
sends back a DR‐TPDU, too, When the timer is lost TPDUs.
and starts a timer. expired, the After ‘N’ entries,
connection
When this DR arrives, the is released. the sender just
original sender sends back an gives up and
ACK‐ TPDU and releases the Releases
connection. connection.
Finally, when the ACK‐
TPDU arrives,
the
receiver also
releases
theconnection.

in existence.
 When the second delayed segment arrives at host 2, the fact that z has been
acknowledged rather than y tells host 2 that this, too, is an old duplicate.
 The important thing to realize here is that there is no combination of old
segments that can cause the protocol to fail and have a connection set up by
accident when no one wants it.

CONNECTION RELEASE:

A connection is released using either asymmetric or symmetric variant. But,


the improved protocol for releasing a connection is a 3‐way handshake protocol.
There are two styles of terminating a connection:
I. Asymmetric release and
II. Symmetric release.
Asymmetric release is the way the telephone system works: when one party
hangs up, the connection is broken. Symmetric release treats the connection as
two separate unidirectional connections and requires each one to be released
separately.
16. Describe in brief about TCP segment Header

TCP Segment Header:-

Transmission Control Protocol (TCP) Segment Header consists the


following fields.

Transmission Control Protocol (TCP) Segment Header.

Source port: 16 Bit number which identifies the Source Port number (Sending
Computer's TCP Port).

Destination port: 16 Bit number which identifies the Destination Port number
(Receiving Port).
Sequence number: 32 Bit number used for byte level numbering of TCP
segments. If you are using TCP, each byte of data is assigned a sequence number.
If SYN flag is set (during the initial three way handshake connection initiation), then
this is
the initial sequence number. The sequence number of the actual first data byte
will then be this sequence number plus 1. For example, let the first byte of data
by a device in a particular TCP header will have its sequence number in this field
50000.
If this packet has 500 bytes of data in it, then the next packet sent by this device
will have the sequence number of 50000 + 500 + 1 = 50501.
Acknowledgment Number: 32 Bit number field which indicates the next sequence
number that the sending device is expecting from the other device.

Header Length: 4 Bit field which shows the number of 32 Bit words in the header. Also
known as the Data Offset field. The minimum size header is 5 words (binary pattern is
0101).
Reserved: Always set to 0 (Size 6 bits).

Control Bit Flags: We have seen before that TCP is a Connection Oriented Protocol.
The meaning of Connection Oriented Protocol is that, before any data can be
transmitted, a reliable connection must be obtained and acknowledged.

Control Bits govern the entire process of connection establishment, data transmissions
and connection termination. The control bits are listed as follows: They are:

URG: Urgent Pointer.

ACK: Acknowledgement.

PSH: This flag means Push function. Using this flag, TCP allows a sending application to
specify that the data must be pushed immediately. When an application requests the
TCP to push data, the TCP should send the data that has accumulated without waiting
to fill the segment.

RST: Reset the connection. The RST bit is used to RESET the TCP connection due to
unrecoverable errors. When an RST is received in a TCP segment, the receiver must
respond by immediately terminating the connection. A RESET causes both sides
immediately to release the connection and all its resources. As a result, transfer of data
ceases in both directions, which can result in loss of data that is in transit. A TCP RST
indicates an abnormal termination of the connection.

SYN: This flag means synchronize sequence numbers. Source is beginning a new
counting sequence. In other words, the TCP segment contains the sequence number
of the first sent byte (ISN).

FIN: No more data from the sender. Receiving a TCP segment with the FIN flag does not
mean that transferring data in the opposite direction is not possible. Because TCP is a
fully duplex connection, the FIN flag will cause the closing of connection only in one
direction. To close a TCP connection gracefully, applications use the FIN flag.

Window: indicates the size of the receive window, which specifies the number of bytes
beyond the sequence number in the acknowledgment field that the receiver is currently
willing to receive.
Checksum: The 16‐bit checksum field is used for error‐checking of the header and
data.
Urgent Pointer: Shows the end of the urgent data so that interrupted data streams can
continue. When the URG bit is set, the data is given priority over other data streams
(Size 16 bits).
UNIT - V
Application Layer –Domain name system, SNMP, Electronic Mail; the
World WEB, HTTP, Streaming audio and video.
1. Why do we need a Domain Name System? What role does the DNS
Resolver play in the DNS system?
Domain Name System can map a name to an address and conversely an
address to name. The Domain Name System converts domain names into IP
numbers. IP numbers uniquely identify hosts on the Internet.

2. What are the functions of Application Layer?


It enables the user (human/software) to access the network. It provides
user interfaces and support for services such as electronic mail, remote file
access and transfer, shared database management and other types of
distributed information services. Services provided by the application layer
are Network Virtual terminal, File transfer, access and management. Mail
services, Directory
services.

3. What are the four main properties of HTTP?


• Global Uniform Resource Identifier.
• Request-response exchange.
• Statelessness.
• Resource metadata.

4. List the two types of DNS message.


There are two types of DNS messages – Query and Response
Query message – consists of the header and question records.
Response message – consists of header, question record, authoritative record
and additional record.

5. Describe why HTTP is defined as a stateless protocol.


Maintaining state across request – Response connections
significantly increases the initial interactions in a connection, since the identity of
each party needs to be established and any saved state much be retrieved. HTTP is
therefore stateless to ensure that internet is scalable since state is not contained in
a HTTP request /response pair by default.

6. State the purpose of SNMP.


Simple Network Management Protocol (SNMP) is a standard internet
protocol enabling certain nodes in a network (the management stations or
managing nodes) to query other network components or applications for
information about their status and activities. Such a query is known as an
SNMP poll.

7. Why email security is necessary?


It is the process of using email encryption to send messages that can only be
opened by the intended recipient. Secure email encryption protects both your
online data and customers sensitive information.

8. What are the four groups of HTTP Headers? What are the two methods of
HTTP?
The four groups of HTTP headers are
• General headers
• Entity Headers
• Request Headers
• Response Headers.
Two methods of HTTP are Get Method( ) Post Method( )

9. Define SNMP.
Simple Network Management Protocol (SNMP) is an "Internet- standard protocol
for managing devices on IP networks". Devices that typically support SNMP include
routers, switches, servers, workstations, printers, & modem. It is used mostly in
network management systems to monitor network-attached devices for
conditions that warrant administrative attention.

10. List the two types of DNS message.


There are two types of DNS messages,
• Query
• Response
Query message – consists of the header and question records.
Response message – consists of header, question record,
authoritative record and additional record.
11. Define SCTP

SCTP (Stream Control Transmission Protocol) is a reliable, message-oriented


transport layer protocol. It combines the best features of UDP and TCP. It is
mostly designed for internet applications.

PART B
12. What is DNS? What are the services provided by DNS and explain
how it works.
An application layer protocol defines how the application processes
running on different systems, pass the messages to each other.

 DNS stands for Domain Name System.


 DNS is a directory service that provides a mapping between the name
of a host on the network and its numerical address.
 DNS is required for the functioning of the internet.
 Each node in a tree has a domain name, and a full domain name is a
sequence of symbols specified by dots.
 DNS is a service that translates the domain name into IP addresses. This
allows the users of networks to utilize user-friendly names when
looking for other hosts instead of remembering the IP addresses.
 For example, suppose the FTP site at EduSoft had an IP address of
132.147.165.50, most people would reach this site by specifying
ftp.EduSoft.com. Therefore, the domain name is more reliable than IP
address.
DNS is a TCP/IP protocol used on different platforms. The domain name
space is divided into three different sections: generic domains, country
domains, and inverse domain.
Generic Domains
 It defines the registered hosts according to their generic behavior.
 Each node in a tree defines the domain name, which is an index to the
DNS database.
 It uses three-character labels, and these labels describe the
organization type.

Country Domain
The format of country domain is same as a generic domain, but it uses two-
character country abbreviations (e.g., us for the United States) in place of
three character organizational abbreviations.

Inverse Domain
The inverse domain is used for mapping an address to a name. When the
server has received a request from the client, and the server contains the files
of only authorized clients. To determine whether the client is on the
authorized list or not, it sends a query to the DNS server and ask for mapping
an address to the name.

Working of DNS
 DNS is a client/server network communication protocol. DNS clients
send requests to the. server while DNS servers send responses to the
client.
 Client requests contain a name which is converted into an IP address
known as a forward DNS lookups while requests containing an IP
address which is converted into a name known as reverse DNS lookups.
 DNS implements a distributed database to store the name of all the
hosts available on the internet.
 If a client like a web browser sends a request containing a hostname,
then a piece of software such as DNS resolver sends a request to the
DNS server to obtain the IP address of a hostname.
 If DNS server does not contain the IP address associated with a
hostname, then it forwards the request to another DNS server.
 If IP address has arrived at the resolver, which in turn completes the
request over the internet protocol.

13. Explain about SNMP with a neat sketch


 SNMP stands for Simple Network Management Protocol.
 SNMP is a framework used for managing devices on the internet.
 It provides a set of operations for monitoring and managing the
internet.
 SNMP has two components Manager and agent.
 The manager is a host that controls and monitors a set of agents such as
routers.
 It is an application layer protocol in which a few manager stations can
handle a set of agents.
 The protocol designed at the application level can monitor the devices
made by different manufacturers and installed on different physical
networks.
 It is used in a heterogeneous network made of different LANs and
WANs connected by routers or gateways.
Managers & Agents
 A manager is a host that runs the SNMP client program while the agent
is a router that runs the SNMP server program.
 Management of the internet is achieved through simple interaction
between a manager and agent.
 The agent is used to keep the information in a database while the
manager is used to access the values in the database. For example, a
router can store the appropriate variables such as a number of packets
received and forwarded while the manager can compare these
variables to determine whether the router is congested or not.
 Agents can also contribute to the management process. A server
program on the agent checks the environment, if something goes
wrong, the agent sends a warning message to the manager.
Management with SNMP has three basic ideas:
 A manager checks the agent by requesting the information that reflects
the behavior of the agent.
 A manager also forces the agent to perform a certain function by
resetting values in the agent database.
 An agent also contributes to the management process by warning the
manager regarding an unusual condition.
Management Components
 Management is not achieved only through the SNMP protocol but also
the use of other protocols that can cooperate with the SNMP protocol.
Management is achieved through the use of the other two protocols:
SMI (Structure of management information) and MIB(management
information base).
 Management is a combination of SMI, MIB, and SNMP. All these three
protocols such as abstract syntax notation 1 (ASN.1) and basic encoding
rules (BER).

SMI

The SMI (Structure of management information) is a component used in


network management. Its main function is to define the type of data that
can be stored in an object and to show how to encode the data for the
transmission over a network .
MIB

 The MIB (Management information base) is a second component for


the network management.

 Each agent has its own MIB, which is a collection of all the objects
that the manager can manage. MIB is categorized into eight groups:
system, interface, address translation, ip, icmp, tcp, udp, and egp.
These groups are under the mib object.
SNMP

 SNMP defines five types of messages: GetRequest, GetNextRequest,


SetRequest, GetResponse, and Trap.

GetRequest: The GetRequest message is sent from a manager (client) to


the agent (server) to retrieve the value of a variable.

GetNextRequest: The GetNextRequest message is sent from the manager


to agent to retrieve the value of a variable. This type of message is used to
retrieve the values of the entries in a table. If the manager does not know
the indexes of the entries, then it will not be able to retrieve the values. In
such situations, GetNextRequest message is used to define an object.
GetResponse: The GetResponse message is sent from an agent to the
manager in response to the GetRequest and GetNextRequest message. This
message contains the value of a variable requested by the manager.

SetRequest: The SetRequest message is sent from a manager to the agent


to set a value in a variable.

Trap: The Trap message is sent from an agent to the manager to report an
event. For example, if the agent is rebooted, then it informs the manager as
well as sends the time of rebooting.

14. What is electronic mail? Explain how it works.

Email consists of two kinds of subsystems: the user agents, which allow
people to read and send email, and the message transfer agents, which
move the messages from the source to the destination. We will also refer
to message transfer agents informally as mail servers.

The message transfer agents are typically system processes. They run
in the background on mail server machines and are intended to be always
available. Their job is to automatically move email through the system
from the originator to the recipient with SMTP (Simple Mail Transfer
Protocol). This is the message transfer step.

SMTP was originally specified as RFC 821 and revised to become the
current RFC 5321.
SMTP stands for Simple Mail Transfer Protocol.

SMTP is a set of communication guidelines that allow software to


transmit an electronic mail over the internet is called Simple Mail Transfer
Protocol.

 It is a program used for sending messages to other computer users


based on e- mail addresses.

 It provides a mail exchange between users on the same or different


computers, and it also supports:

 It can send a single message to one or more recipients.

 Sending message can include text, voice, video or graphics.

 It can also send the messages on networks outside the internet.

 The main purpose of SMTP is used to set up communication rules


between servers. The servers have a way of identifying themselves
and announcing what kind of communication they are trying to
perform. They also have a way of handling the errors such as
incorrect email address. For example, if the recipient address is
wrong, then receiving server reply with an error message of some
kind.
Components of SMTP
First, we will break the SMTP client and SMTP server into two components such
as user agent (UA) and mail transfer agent (MTA). The user agent (UA) prepares

the message, creates the envelope and then puts the message in the envelope. The
mail transfer agent (MTA) transfers this mail across the internet.
 SMTP allows a more complex system by adding a relaying system.
Instead of just having one MTA at sending side and one at receiving
side, more MTAs can be added, acting either as a client or server to
relay the email.

 The relaying system without TCP/IP protocol can also be used to


send the emails to users, and this is achieved by the use of the mail
gateway. The mail gateway is a relay MTA that can be used to receive
an email.
Working of SMTP

1. Composition of Mail: A user sends an e-mail by composing an


electronic mail message using a Mail User Agent (MUA). Mail User
Agent is a program which is used to send and receive mail. The
message contains two parts: body and header. The body is the main
part of the message while the header includes information such as
the sender and recipient address. The header also includes
descriptive information such as the subject of the message. In this
case, the message body is like a letter and header is like an envelope
that contains the recipient's address.

2. Submission of Mail: After composing an email, the mail client then


submits the completed e-mail to the SMTP server by using SMTP on
TCP port 25.

3. Delivery of Mail: E-mail addresses contain two parts: username of


the recipient and domain name. For example, suresh@gmail.com,
where "suresh" is the username of the recipient and "gmail.com"
is the domain name. If the domain name of the recipient's email
address is different from the sender's
4. Domain name, then MSA will send the mail to the Mail Transfer
Agent (MTA). To relay the email, the MTA will find the target
domain. It checks the MX record from Domain Name System to
obtain the target domain. The MX record contains the domain name
and IP address of the recipient's domain. Once the record is located,
MTA connects to the exchange server to relay the message.

5. Receipt and Processing of Mail: Once the incoming message is


received, the exchange server delivers it to the incoming server
(Mail Delivery Agent) which stores the e-mail where it waits for the
user to retrieve it.

6. Access and Retrieval of Mail: The stored email in MDA can be


retrieved by using MUA (Mail User Agent). MUA can be accessed by
using login and password.

SMTP MESSAGE HEADER

The Post Office Protocol (POP) is an application-layer Internet standard


protocol used by local e-mail clients to retrieve e-mail from a remote
server over a TCP/IP connection.[1] POP has been developed through
several versions, with version 3 (POP3) being the current standard.

POP supports simple download-and-delete requirements for access


to remote mailboxes (termed mail drop in the POP RFC's).[3] Although
most POP clients have an option to leave mail on server after download, e-
mail clients using POP generally connect, retrieve all messages, store them
on the user's PC as new messages, delete them from the server, and then
disconnect.
POP3 is designed to delete mail on the server as soon as the user has
downloaded it. However, some implementations allow users or an
administrator to specify that mail be saved for some period of time. POP
can be thought of as a "store-and-forward" service.

IMAP, (Internet Message Access Protocol) provide more complete and


complex remote access to typical mailbox operations. In the late 1990sand
early 2000s, fewer Internet Service Providers (ISPs) supported IMAP due
to the storage space that was required on the ISP's hardware.
Contemporary e-mail clients supported POP, then over time popular mail
client software added IMAP support.

IMAP stands for Internet Message Access Protocol. IMAP shares many
similar features with POP3. It, too, is a protocol that an email client can use
to download email from an email server. However, IMAP includes many
more features than POP3.

Multipurpose Internet Mail Extensions (MIME) is an Internet


standard that extends the format of email to support:

 Text in character sets other than ASCII

 Non-text attachments: audio, video, images, application programs


etc.

 Message bodies with multiple parts

 Header information in non-ASCII character sets

Virtually all human-written Internet email and a fairly large proportion of


automated email is transmitted via SMTP in MIME format.

MIME is specified in six linked RFC memoranda: RFC 2045, RFC 2046, RFC
2047, RFC 4288, RFC 4289 and RFC 2049; with the

integration with SMTP email specified in detail in RFC1521 and RFC 1522.

Although MIME was designed mainly for SMTP, the content types
defined by MIME standards are also of importance outside of email, such
as in communication protocols likeHTTP for the World Wide Web. Servers
insert the MIME header at the beginning of any Web transmission.
Clients use this content type or Internet media type header to select an
appropriate "player" application for the type of data the header indicates.
Some of these players are built into the Web client or browser (for
example, almost all browsers come with GIF and JPEG image players as
well as the ability to handle HTML files);

Multipurpose Internet Mail Extensions, a specification for formatting


non-ASCII messages so that they can be sent over the Internet. Many e-
mail clients now support MIME,which enables them to send and receive
graphics, audio, and video files via the Internet mail system. In addition,
MIME supports messages in character sets other than ASCII.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy