CN KCS-603 Important Questions Solved
CN KCS-603 Important Questions Solved
CN KCS-603 Important Questions Solved
Answer
1. Copper Wire
2. Optical Fibre
3. Microwave
4. Satellite
OR
Speed of Network:
Bit rate:
It can be determined as “How many bits can be placed on the network in a given time interval
(say,1 second)”?
OR
The bit rate is the number of bits that pass a given point in a telecommunication
Latency:
It can be determined as “How long does it take a bit to be received by the destination node?”
Latency becomes the dominant factor when sending individual packets, or alternating
sending/receiving
Goals of Computer Networks: The following are some important goals of computer networks:
Resource Sharing –
Many organizations have a substantial number of computers in operations, which are
located apart,for instance A group of office workers can share a common printer, fax,
modem, scanner, etc.
High Reliability –
If there are alternate sources of supply, all files could be replicated on two or more
machines. If one of them is not available, due to hardware failure, the other copies could
be used.
Inter-process Communication –
Network users, located geographically apart, may communicate in an interactive session
via network,for this,the network must provide almost error-free communications.
Flexible access –
Accessibility is the measure through which Files can be accessed from any computer in
the network.
Centralized management
Scalability
Applications of Networks:
Computer networks support an enormous number of applications and services such as:
OR
OR
Explain functionalities of every layer in the OSI reference model with a neat block
diagram.
AKTU 2016-17, Marks 7.5
Answer
The OSI model is a layered framework for the design of network systems that allows
communication between all types of computer systems. It consists of seven separate but
related layers, each of which defines a part of the process of moving information across a
network .
Description:
OSI Model breaks down how information and requests are sent from one computer to
another, starting at the user making a request and ending at that information traveling over
some transmission medium.
Duty of Each Layer: To make sure that information is being passed correctly between the
layers above and below it, and if all the layers are doing their jobs, your computer will be able
to communicate with others.
Layers:
The Physical Layer communicates directly with the various types of actual communication
media.The Physical Layer specifies the electrical, mechanical, procedural and functional
requirements for activating, maintaining & deactivating a physical link between end
systems.The main functionality of the physical layer is to transmit the individual bits from one
node to another node.It is the lowest layer of the OSI model.
1. Data Link Layer:The DLL provides Physical Transmission of the Data and handles error
notification, network topology and flow control. That means that DLL will make sure that
the messages are delivered to the proper device on a LAN using a hardware address
and will translate messages from the Network Layer into bits for the Physical Layer to
transmit. Data is in the form of Frames here.The DLL consists of two sublayers :-
2. MAC (Media Access Control)
3. LLC ( Logical Link Control)
4. Network Layer:It manages device addressing, tracks the location of devices on the
network and determines the best way to move data, which means that the NL must
support transport traffic between devices that aren’t locally attached.Routers are
specified at the NL and provide the routing services.It is a layer 3 that manages device
addressing, tracks the location of devices on the network.
Ques 4 What is OSI model? Explain the functions, protocols and services of each layer.
Answer
1. Application
1. Functions:The application layer is used by end-user software such as web
browsers and email clients. It provides protocols that allow software to send and
receive information and present meaningful data to users and includes identifying
communication partners, determining resource availability, and synchronizing
communication.
2. Protocols:
1. Hypertext Transfer Protocol (HTTP)
2. File Transfer Protocol (FTP)
3. Post Office Protocol (POP),
3. Services:It uses the services of the transport layer, the network layer, the data
link layer, and the physical layer to transfer data to a remote host.
2. Presentation
1. Functions:It deals with the syntax and the semantics of the messages. It encodes
the messages from the user dependent format to the common format and vice
versa, for communication among dissimilar systems. It is responsible for data
encryption and decryption of sensitive data before they are transmitted over
common channels.
2. Protocols:
1. SSL
2. HTTP/ HTML (agent)
3. FTP (server)
4. Telnet
3. Services:It translates data between the formats the network requires and the
format the computer.
3. Session
1. Functions:The session layer provides the mechanism for opening, closing and
managing a session between end-user application processes, i.e.a
semi-permanent dialogue,controls the dialogues (connections) between
computers.
2. Protocols:Session Initiation Protocol (SIP) is used to signal and control
interactive communication sessions
3. Services:It establishes, manages, and terminates the connections between the
local and remote application.
4. Transport
1. Functions:Transport Layer provides transparent transfer of data between end
users, providing reliable data transfer services to the upper layers. The transport
layer controls the reliability of a given link through flow control, segmentation and
desegmentation, and error control.
2. Protocols:
1. Transmission Control Protocol (TCP)
2. User Datagram Protocol (UDP)
3. Services:It provides services such as connection-oriented communication,
reliability, flow control, and multiplexing.
5. Network
1. Functions:breaking up segments into network packets, and reassembling the
packets on the receiving end and routing packets by discovering the best path
across a physical network.
2. Protocols:
1. Internet Protocol (IP)
3. Services:Connection services are provided including network layer flow control,
network layer error control and packet sequence control.
6. Data Link
1. Functions:Data Link Layer provides the functional and procedural means to
transfer data between network entities and to detect and possibly correct errors
that may occur in the physical layer
2. Protocols:
1. Ethernet for local area networks (multi-node)
2. The Point-to-Point Protocol (PPP)
3. HDLC and ADCCP for point-to-point (dual-node) connections.
3. Services:Encapsulation of network layer data packets into frames and Frame
synchronization.
7. Physical
1. Functions:Physical Layer defines electrical and physical specifications for
devices. The physical layer defines the relationship between a device and a
transmission medium, such as a copper or optical cable.
2. Protocols:
1. Infrared Data Association
2. Bluetooth.
3. Ethernet
Services:
Modulates the process of converting a signal from one form to another so that it can be
physically transmitted over a communication channel.
OR
Discuss the TCP/IP protocol suite on the basis of protocol layering principle.
Answer:
The first layer is the Process layer on the behalf of the sender and Network Access layer on
the behalf of the receiver. During this article, we will be talking on the behalf of the receiver.
This layer corresponds to the combination of Data Link Layer and Physical Layer of the OSI
model. It looks out for hardware addressing and the protocols present in this layer allows for
the physical transmission of data. Network Access Layer is responsible for several things;
including error checking, formatting data into frames, and interfacing with network adapters.
We know that ARP being a protocol of Internet layer,there is a conflict about declaring it as a
protocol of Internet Layer or Network access layer. It resides in layer 3, being encapsulated by
layer 2 protocols.
2. Internet Layer –
This layer parallels the functions of OSI’s Network layer. It defines the protocols which are
responsible for logical transmission of data over the entire network.The Internet layer offers
the functional and procedural method for transferring variable length data sequences from
one node to another with the help of various networks. The main protocols residing at this
layer are :
1. IP (Internet Protocol):Responsible for delivering packets from the source host to the
destination host by looking at the IP addresses in the packet headers.
2. ICMP(Internet Control Message Protocol):It is encapsulated within IP datagrams and is
responsible for providing hosts with information about network problems.
3. ARP(Address Resolution Protocol)Its job is to find the hardware address of a host from
a known IP address.
3. Host-to-Host Layer:The protocol layer just above the internetwork layer is the
host-to-host layer. It is responsible for end-to-end data integrity. The two most important
protocols employed at this layer are the Transmission Control Protocol (TCP) and User
Datagram Protocol (UDP).The two main protocols present in this layer are :
4. Application Layer:
This layer performs the functions of the top three layers of the OSI model: Application,
Presentation and Session Layer. It is responsible for node-to-node communication and
controls user-interface specifications.The application layer is the highest abstraction layer of
the TCP/IP model that provides the interfaces and protocols needed by the users. It provides
user services like user login, naming network devices, formatting messages, and e-mails,
transfer of files etc.
Protocols:
1. HTTP and HTTPS – HTTP(Hypertext transfer protocol):It is used by the World Wide
Web to manage communications between web browsers and servers.
HTTPS(HTTP-Secure): It is a combination of HTTP with SSL(Secure Socket Layer).
2. SSH(Secure Shell): It is a terminal emulation software similar to Telnet. The reason
SSH is more preferred is because of its ability to maintain the encrypted connection. It
sets up a secure session over a TCP/IP connection.
3. NTP(Network Time Protocol)It is used to synchronize the clocks on our computer to
one standard time source. It is very useful in situations like bank transactions. Assume
the following situation without the presence of NTP.
Answer:
The Most Important Difference lies in the layers present in both models:
TCP/IP Model OSI Model
TCP/IP helps to determine how a specific The OSI Model is a logical and conceptual
computer should be connected to the internet and model that defines network communication used
how you can be transmitted between them. by systems open to interconnection and
communication with other systems.
The transport layer present here is both The transport layer present here is only
connection oriented and connectionless. connection oriented.
It consists of standard protocols that lead to the It is an independent standard and generic
development of an internet. It is a communication protocol used as a communication gateway
protocol that provides the connection among the between the network and the end user.
hosts.
Answer
1. It is a network service that was designed and developed after the telephone system.
2. Used to create an end to end(dedicated) connection between the sender and the
receiver before transmitting the data over the same or different networks.
3. Packets are transmitted to the receiver in the same order the sender has sent them.
4. Connection may be terminated when session is complete or may be permanent.
5. TCP (Transmission Control Protocol) is a connection-oriented protocol that allows
communication between two or more computer devices by establishing connections in
the same or different networks.
6. It is the most important protocol that uses internet protocol to transfer the data from one
end to another.
7. Connection Less Services:
1. Connectionless service is used in the network system to transfer data from one end to
another end without creating any connection.
2. So it does not require establishing a connection before sending the data from the
sender to the receiver.
3. It is not a reliable network service because it does not guarantee the transfer of data
packets to the receiver, and data packets can be received in any order to the receiver.
4. There’s no need to set up a connection before sending a message and relinquish it
after the message has been sent.
5. The data packets in a connectionless service are usually called datagrams.
6. It uses Internet Protocol,User Datagram Protocol and Internet Control Message
Protocol.
Answer
1. A service is specified by a set of primitives available to a user process to access the
service.
2. Sockets are a service provided by a transport layer.
3. A socket is one endpoint of a two-way communication link between two programs
running on the network.
I) Server side:
Ques 9 What do you mean by topology? Explain in brief any three such network
topologies.
OR
Explain network topological design with necessary diagrams and brief the advantages
and disadvantages of various topologies.
OR
Define topology and explain the advantage and disadvantage of bus, star and ring
topologies.
Answer
1. Linear
2. Ring
3. Star
Types of Topologies:
1. Bus
Bus topology is a network type in which every computer and network device is connected to
single cable. It transmits the data from one end to another in single direction. No bi-directional
feature is in bus topology.
Advantages:
Disadvantages:
A ring topology is a network configuration where device connections create a circular data
path. Each networked device is connected to two others, like points on a circle.Most ring
topologies allow packets to travel only in one direction, called a unidirectional ring network.
Advantages:
Disadvantages:
1. If you sever one point of the topology, then the entire network malfunctions.
2. Ring topologies are one of the slowest network designs.
3. It is more expensive to install a ring topology network.
4. The bandwidth of a ring topology gets shared on all links between devices.
5. Star
A star topology is a topology for a Local Area Network (LAN) in which all nodes are
individually connected to a central connection point, like a hub or a switch. The central hub is
usually a fast, self contained computer and is responsible for routing all traffic to other nodes
Advantages:
Disadvantages:
Ques 10 What are the number of cable links required for a device connected in mesh,
ring, bus and star topology?
Answer:
For n devices,
Answer:
There are four type of delays possible in networks mainly in packet switching networks:
1. Transmission Delay
2. Propagation Delay
3. Queuing Delay
4. Processing Delay
1.Transmission Delay:
Time taken to put a packet onto the link. In other words, it is simply time required to put data
bits on the wire/communication medium. It depends on the length of the packet and the
bandwidth of the network.
2.Propagation delay:
Time taken by the first bit to travel from sender to receiver end of the link. In other words, it is
simply the time required for bits to reach the destination from the start point. Factors on which
Propagation delay depends are Distance and propagation speed.
3.Queuing Delay:
Queuing delay is the time a job waits in a queue until it can be executed. It depends on
congestion. It is the time difference between when the packet arrived Destination and when
the packet data was processed or executed. It may be caused by mainly three reasons i.e.
originating switches, intermediate switches or call receiver servicing switches.
4.Processing Delay:
Processing delay is the time it takes routers to process the packet header. Processing of
packets helps in detecting bit-level errors that occur during transmission of a packet to the
destination. Processing delays in high-speed routers are typically on the order of
microseconds or less. In simple words, it is just the time taken to process packets.
OR
Answer:
1. Poor Reliability:The reliability will be poor since a service interruption even for a short
duration can cause major problems to the user.
2. Capacity:It may be saturated due to increase in number of devices beyond a certain
number
3. Cost:A single LAN can not give its optimum performance for the diverse requirements
of communication and interconnection.
So the alternative for using a single LAN is to use low cost low capacity LANs in each building
or department and then interconnect all these LANs with high capacity LAN. such a network is
called Backbone LAN.
The backbone itself is a LAN, it uses a LAN protocol such as ethernet, Hence each
connection in the backbone is itself another LAN. LANs are interconnected with routers that
form the backboneThe two very common used architectures are: Bus backbone, Star
backbone.
1. Bus Backbone:
In Bus backbone the topology used for the backbone is bus topology.
In above the Bus backbone structure is used as a distribution backbone for connecting
different buildings in an organization. In this configuration, the backbone is just one
switch (that is why it is called, erroneously, a collapsed backbone) that connects the
LANs.Devices share responsibility for getting data from one point to another.
2. Star Backbone:The topology of this backbone is star topology.In a star backbone, the
topology of the backbone is a star; the backbone is just one switch.
The backbone is simply a switch which is used to connect various LANs.Every node on the
network is connected through a central device.Any single cable connects only two devices
Ques 13 Discuss local access networks. What are the different types of access network?
Answer:
An access network is a type of network which physically connects an end system to the
immediate router (also known as the “edge router”) on a path from the end system to any
other distant end system.
1. Ethernet:Ethernet is the most popular physical layer LAN technology in use today. It
defines the number of conductors that are required for a connection, the performance
thresholds that can be expected, and provides the framework for data transmission. A
standard Ethernet network can transmit data at a rate up to 10 Megabits per second
(10 Mbps). Ethernet is popular because it strikes a good balance between speed, cost
and ease of installation. These benefits, combined with wide acceptance in the
computer marketplace and the ability to support virtually all popular network protocols,
make Ethernet an ideal networking technology for most computer users today.
2. 3G and LTE:The term “3G internet” refers to the third generation of mobile phone
standards as set by the International Telecommunications Union (ITU). Long Term
Evolution (LTE) offers high-speed wireless communication for mobile devices and
increased network capacity.The basic difference between them is the speed of the
network
3. Wireless LAN:Wireless LANs (WLANs) are wireless computer networks that use high-frequency radio
waves instead of cables for connecting the devices within a limited area forming LAN (Local Area Network).
WLAN is one in which a mobile user can connect to a Local Area Network (LAN) through a wireless
connection.Users connected by wireless LANs can move around within this limited area such as home,
school, campus, office building, railway platform, etc.
4. FTTH:Fiber to the home (FTTH) is the delivery of a communications signal over optical
fiber from the operator's switching equipment all the way to a home or business,
thereby replacing existing copper infrastructure such as telephone wires and coaxial
cable.That's why fiber networks are said to be “future proof.”Fiber to the home (FTTH)
uses optical fiber from a central Office (CO) directly to individual buildings and it
provides high-speed Internet access among all access networks.
5. DSL:DSL stands for Digital Subscriber Line and DSL brings a connection into your
home through telephone lines and a DSL line can carry both data and voice signals and
the data part of the line is continuously connected. In DSL you are able to use the
Internet and make phone calls simultaneously.DSL (Digital Subscriber Line) is a
modem technology that uses existing telephone lines to transport high-bandwidth data,
such as multimedia and video, to service subscribers. DSL provides dedicated,
point-to-point, public network access.
Ques 14 What do you mean by transmission media? Discuss the types of transmission
media.
OR
Answer
The transmission medium can be defined as a pathway that can transmit information from a
sender to a receiver. Transmission media are located below the physical layer and are
controlled by the physical layer. Transmission media are also called communication channels.
Coaxial cable
OR
Answer:
Guided Media:
It is defined as the physical medium through which the signals are transmitted.Signals being
transmitted are directed and confined in a narrow pathway by using physical links.
Features:
● High Speed
● Secure
● Used for comparatively shorter distances
It consists of 2 separately insulated conductor wires wound about each other. Installation of
the twisted pair cable is easy, and it is a lightweight cable. The frequency range for twisted
pair cable is from 0 to 3.5KHz.Generally, several such pairs are bundled together in a
protective sheath.
Advantages:
Disadvantages:
● It is incapable of carrying a signal over long distances without the use of repeaters only
because of high attenuation.
● It is not suitable for broadband applications only because of its low bandwidth
capabilities.
The name of the cable is coaxial as it contains two conductors parallel to each other.It has an
outer plastic covering containing 2 parallel conductors each having a separate insulated
protection cover. The coaxial cable transmits information in two modes: dedicated cable
bandwidth and when cable bandwidth is split into separate ranges.Cable TVs and analog
television networks widely use Coaxial cables.
Advantages:
● High Bandwidth
● It has better shielding as compared to twisted pair cable.
● Easy to install and expand
● Inexpensive
Disadvantages:
Fibre optic is a cable that holds the optical fibres coated in plastic that are used to send the
data by pulses of light.The core is surrounded by a less dense glass or plastic covering called
the cladding. Fibre optics provide faster data transmission than copper wires.It is used for the
transmission of large volumes of data. The cable can be unidirectional or bidirectional.
Advantages:
Disadvantages:
Answer
OR
Answer
In large networks there might be multiple paths linking sender and receiver. Information may
be switched as it travels through various communication channels. There are three typical
switching techniques available for digital traffic
1.Circuit switching is a technique that directly connects the sender and the receiver in an
unbroken path.Circuit switching in a network operates almost the same way as the telephone
system works. A complete end-to-end path must exist before communication can take place.
Advantages:
Disadvantages:
● Possible long wait to establish a connection, during which no data can be transmitted.
● Inefficient use of the communication channel, because the channel is not used when
the connected systems are not using it.
2.Message Switching:There is no need to establish a dedicated path between two
stations.When a station sends a message, the destination address is appended to the
message.The message is then transmitted through the network, in its entirety, from node to
node.Each node receives the entire message, stores it in its entirety on disk, and then
transmits the message to the next node.
Advantages:
Disadvantages:
3.Packet switching can be seen as a solution that tries to combine the advantages of
message and circuit switching and to minimize the disadvantages of both.There are two
methods of packet switching: Datagram and virtual circuit.In both packet switching methods, a
message is broken into small parts, called packets.Each packet is tagged with appropriate
source and destination addresses.
Advantages:
● Packet switching is cost effective, because switching devices do not need a massive
amount of secondary storage.
Disadvantages:
Ques 18 Write a short note on ISDN. What are the features of ISDN?
OR
What are the channel types in ISDN to construct transmission structure of any access
link? Discuss.
Answer
These are a set of communication standards for simultaneous digital transmission of voice,
video, data, and other network services over the traditional circuits of the public switched
telephone network.
Before Integrated Services Digital Network (ISDN), the telephone system was seen as a way
to transmit voice, with some special services available for data.
Features:
1. It can integrate speech and data on the same lines, which were not available in the
classic telephone system.
2. ISDN is a circuit-switched telephone network system, but it also provides access to
packet switched networks that allows digital transmission of voice and data.
3. It provides potentially better voice or data quality than an analog phone can provide.
4. It provides a packet-switched connection for data in increments of 64 kilobit/s.
5. It provided a maximum of 128 kbit/s bandwidth in both upstream and downstream
directions.
6. A greater data rate was achieved through channel bonding. Generally ISDN B-channels
of three or four BRIs (six to eight 64 kbit/s channels) are bonded.
7. ISDN provides simultaneous voice, video, and text transmission between individual
desktop videoconferencing systems and group video conferencing systems.
Answer
Terminal Handling:
1. Terminal Controller is a device that collects traffic from a set of terminals and directs
them to a concentrator.
2. For many applications the cost of communication lines exceeds the cost of the
equipment connected by those lines.
3. In an attempt to reduce communication costs, many networks provide a way for
multiple terminals to share a single communication line.
4. The conceptual model is that of fig, in which a terminal controller accepts input from a
cluster of terminals, and funnels the output onto one line, as well as the reverse
operation.
5. All the terminals are wired onto the same multidrop line, whereas each terminal has its
own point-to-point line to the controller.
6. Terminal controllers can be divided into two general classes, multiplexers and
concentrators.
1. A multiplexer is a device that accepts input from a collection of lines in some static,
predetermined sequence, and outputs the data onto a single output line in the same
sequence.
2. As each output time slot is dedicated to a specific input line, there is no need to
transmit the input line numbers.
3. The output line must have the same capacity as the sum of the input line capacities.
4. A terminal which depends on the host computer for its processing power is known as a
thin client. A personal computer can run software which emulates the function of a
terminal and can sometimes allow concurrent use of local programs and access to a
distant terminal host system.
Ques 21 Differentiate between bit rate and baud rate. A modem constellation diagram
has data points at coordinates:(1,1), (1,-1), (-1,1) and (1,-1). How many bps can a modem
with these parameters achieve at 1200 baud? State two reasons for using layered
protocols.
Answer:
The difference between both is complicated and intertwining.Both are dependent and
inter-related.
Bit Rate Baud Rate
Bit rate is how many data bits are Baud rate is the number of signal units per second. It can be
transmitted per second.Bit rate is defined as per second travel number of bits.Number of
transmission of number of bits per times pers second a signal in a communications channel
second. changes.
Bit rate=baud rate*number of bits per Baud rate=Bit rate/number of bits per baud
baud
1. A software house can create a network program knowing that if it follows the guidelines
of one layer, the services of lower layers will be provided by other companies. This
enables them to specialize.
2. The advantage of using the layered protocols is that the same application i.e., the user
level program can be used by a number of diverse communication networks.
Answer:
Rate,R=10kbps
Signal Power,S=10W
Rate=Bandwidth(log2[1+S/N])
Answer:
Rate=64kbps=64*1000bps
Bandwidth=3kHz=3000Hz
Rate=Bandwidth(log2[1+S/N])
log2[1+S/N]=(64*1000)/3000=64/3
1+S/N=264/3
S/N=264/3-1=264/3dB
Unit 2
Answer
The medium access control (MAC) is a sublayer of the data link layer of the open system
interconnections (OSI) reference model for data transmission.
The protocols used to determine who goes next on a multi-access channel belong to a
sublayer of the data link layer called the MAC (Medium Access Control) sublayer. The MAC
sublayer is especially important in LANs, particularly wireless ones because wireless is
naturally a broadcast channel.WANs, in contrast, use point-to-point links, except for satellite
networks.
Purpose:
It is responsible for flow control and multiplexing for transmission medium. It controls the
transmission of data packets via remotely shared channels. It sends data over the network
interface card.
Functions:
● It provides an abstraction of the physical layer to the LLC and upper layers of the OSI
network.
● It is responsible for encapsulating frames so that they are suitable for transmission via
the physical medium.
● It performs multiple access resolutions when more than one data frame is to be
transmitted. It determines the channel access methods for transmission.
● It generates the frame check sequences and thus contributes to protection against
transmission errors.
Ques 2 Explain channel allocation. What are the two different schemes used for channel
allocation?
Answer
Channel allocation is a process in which a single channel is divided and allotted to multiple
users in order to carry user specific tasks. The user’s quantity may vary every time the
process takes place. If there are N number of users and the channel is divided into N
equal-sized sub channels, Each user is assigned one portion. If the number of users are small
and don’t vary at times, then Frequency Division Multiplexing can be used as it is a simple
and efficient channel bandwidth allocating technique.
● If there are N users, the bandwidth is divided into N equal-sized portions, with each
user being assigned one portion.
● Since each user has a private frequency band, there is now no interference among
users.
● When there is only a small and constant number of users, each of which has a steady
stream or a heavy load of traffic, this division is a simple and efficient allocation
mechanism.
● A wireless example is FM radio stations. Each station gets a portion of the FM band
and uses it most of the time to broadcast its signal.
Answer
● According to this method , each station has the right to the medium without being
controlled by any other station
● Some procedures are defined to resolve the access conflict called collision.
● Collision signifies two or more transmitting nodes
● When node has packet to send
○ Transmit at full channel data rate R
○ No a priori coordination among nodes
● Multiple Access (ALOHA)
○ Any station sends when a frame is ready
○ Waits for an ACK, if not received in allotted time then the frame is resent
● Random Access MAC specifies
○ How to detect collisions
○ How to recover from collisions
● Examples include:
○ ALOHA
○ Slotted ALOHA
○ Carrier Sense Multiple Access(CSMA)
○ CSMA with Collision Detection (CSMA/CD)
○ CSMA with Collision Avoidance (CSMA/CA)
OR
Discuss different carrier sense protocols. How are they different from collision protocols?
Answer
● The CSMA protocol was developed to overcome the problem found in ALOHA i.e. to
minimize the chances of collision, so as to improve the performance.
● The CSMA protocol is based on the principle of ‘carrier sense’. ("sense before transmit"
or "listen before talk)
● The chances of collision can be reduced to great extent if a station senses the channel
before trying to use it.
● Although CSMA can reduce the possibility of collision, it cannot eliminate it completely.
The chances of collision still exist because of propagation delay
● Protocols in which stations listen for a carrier (i.e., a transmission) and act accordingly
are called carrier sense protocols.
● There are three different types of CSMA protocols :
○ 1-Persistent CSMA
○ Non-Persistent CSMA
○ P-Persistent CSMA
● Suppose the channel is currently busy(not free) then Persistent protocol continuously
listens to the channel if it is free or not.(greedy approach) while nonresistant protocol
will wait for a random amount of time before sensing the channel again.
Answer
● When a frame is ready, the transmitting station checks whether the channel is idle or
busy.
● If the channel is busy, the station waits until the channel becomes idle.
● If the channel is idle, the station starts transmitting and continually monitors the channel
to detect collision.
● If a collision is detected, the station starts the collision resolution algorithm.
● The station resets the retransmission counters and completes frame transmission.
OR
CSMA/CA:
● The basic idea behind CSMA/CA is that the station should be able to receive while
transmitting to detect a collision from different stations.
● In wired networks, if a collision has occurred then the energy of received signal almost
doubles and the station can sense the possibility of collision.
● In the case of wireless networks, most of the energy is used for transmission and the
energy of received signal increases by only 5-10% if a collision occurs.
● It can’t be used by the station to sense collision. Therefore CSMA/CA has been
specially designed for wireless networks.
● It means that it is a network protocol that is used to avoid a collision rather than
allowing it to occur, and it does not deal with the recovery of packets after a collision. It
is similar to the CSMA CD protocol that operates in the media access control layer.
Advantages:
1. It controls the data packets and sends the data when the receiver wants to send them.
2. It is used to prevent collision rather than collision detection on the shared channel.
Disadvantages:
1. Sometimes CSMA/CA takes much waiting time as usual to transmit the data packet.
2. It consumes more bandwidth by each station.
3. Its efficiency is less than a CSMA CD.
Answer
CSMA/CD CSMA/CA
To detect the collision on a shared channel. To avoid the collision on a shared channel.
Collision Detection Protocol used in 802.3 Ethernet Collision Avoidance Protocol used in 802.11
Network Cable. Ethernet Network.
Effective after collision detection on a network. Effective before collision detection on a network.
Whenever a data packet conflicts in a shared Whenever the CSMA/CA waits until the channel
channel,it resends the data frame. is busy and does not recover after a collision.
CSMA/CD Applications :
● Modern Ethernet networks, built with switches and full-duplex connections, no longer
need to utilize CSMA/CD because each collision domain is now isolated.
● CSMA/CD is still supported for backwards compatibility and for half-duplex connections
CSMA/CA Applications:
Answer
1- Persistent CSMA:
● When a station has data to send, it first listens to the channel to see if anyone else is
transmitting at that moment.
● If the channel is idle, the station sends its data. Otherwise, if the channel is busy, the
station just waits until it becomes idle. Then the station transmits a frame.
● If a collision occurs, the station waits a random amount of time and starts all over again.
The protocol is called 1-persistent because the station transmits with a probability of 1
when it finds the channel idle.
● In non-persistent CSMA the station does not continuously sense the channel for the
purpose of capturing it when it defects to the end of the previous transmission .
● Consequently, this algorithm leads to better channel utilization but longer delays than
1persistent CSMA.(no collision reduced.)
P- Persistent CSMA:
● It applies to slotted channels such that the time slot duration is equal to or greater than
the maximum propagation delay time.
● When a station becomes ready to send, it senses the channel. If it is idle, it transmits
with a probability p. With a probability q = 1 − p, it defers until the next slot.
● If that slot is also idle, it either transmits or defers again, with probabilities p and q. This
process is repeated until either the frame has been transmitted or another station has
begun transmitting.
Answer
Slotted ALOHA:
1. Divide time into discrete intervals called slots, each interval corresponding to one
frame.
2. A station is not permitted to send whenever the user types a line. Instead, it is required
to wait for the beginning of the next slot. Thus, the continuous time ALOHA is turned
into a discrete time one.
3. This halves the vulnerable period.(t instead of 2t)
4. The probability of no other traffic during the same slot as our test frame is then P0 = e−G
(instead of P0 = e−2G) and S = G,P0 => S = G*e−G
5. Slotted ALOHA peaks at G = 1, with a throughput of S = 1/e or about 0.368, twice that
of pure ALOHA.
6. The best we can hope for using slotted ALOHA is 37% of the slots empty, 37%
successes, and 26% collisions.
Ques 11 How can you compare pure ALOHA and slotted ALOHA.
Answer
Pure ALOHA Slotted ALOHA
Any station can transmit data at any time. Any station can transmit data at the beginning of any
time slot.
The time is continuous and not globally The time is discrete and globally synchronized.
synchronized.
Vulnerable time for pure aloha = 2*Tt Vulnerable time for pure aloha = Tt
It doesn’t reduce the number of collisions to Reduces the number of collisions to half and doubles
half. the efficiency of pure aloha.
Ques 12 A pure ALOHA network transmits 200 bit frames on a shared channel of
200kbps. what is the throughput if the system fall station together) produces 250 frames
per second?
Answer:
In Pure ALOHA,
If the system creates 250 frames per second, or 1/4 frames per millisecond,
then G = ¼.
Ques 13 An ALOHA network uses 19.2kbps channel for sending message packets of
100 bits long size. Calculate the maximum throughput for ALOHA network.
Answer:
In Pure ALOHA,
Efficiency = G * e-2G
If we find in packets/sec then 3.5328/packet size = 3.5328/100 = 0.035328 kilo packets per
second.
Basic frame format which is required for all MAC implementations is defined in IEEE 802.3
standard. Though several optional formats are being used to extend the protocol’s basic
capability.
The Ethernet frame starts with Preamble and SFD, both working at the physical layer.
Ethernet header contains both Source and Destination MAC address, after which the payload
of the frame is present. The last field is CRC which is used to detect the error.
Preamble:
It contains 7 bytes,is a pattern of alternate 0’s and 1’s which indicate starting of the frame and
allow sender and receiver to establish bit synchronization.
This is a 1byte field which is always set to 10101011,which indicates upcoming bits are
starting off the frame(destination address).SFD warns station or stations that this is the last
chance for synchronization.
Destination Address:
6-byte field which contains MAC address of machine for which data is destined.
Source Address:
6 byte field which contains MAC address of source machine.It is always an individual
address(Unicast),the least significant bit of the first byte is always 0.
Length:
2 byte field which indicates the length of the entire Ethernet frame.This is a 16 bit field which
can hold the length value between 0 to 65534,but length cannot be larger than 1500 because
of some limitations of Ethernet.
Data:
Place where actual data is inserted,also known as Payload.Both IP header and data will be
inserted here if Internet Protocol is used over Ethernet.Maximum data present may be as long
as 1500 bytes.
CRC is a 4 byte field. The field contains a 32 bits hash code of data,which is generated over
the destination address,source address,length and data field.If the checksum is not the same
as sent checksum value,data received is corrupted.
Answer
Medium access control :: is provided by a small frame, the token, that circulates around the
ring when all stations are idle. Only the station possessing the token is allowed to transmit at
any given time.
● When a station wishes to transmit, it must wait for the token to pass by and seize the
token.
○ One approach: change one bit in token which transforms it into a normal data
frame and appends frames for transmission.
○ Second approach: station claims token by removing it from the ring.
● The data frame circles the ring and is removed by the transmitting station.
● Each station interrogates the passing frame. If destined for a station, it copies the frame
into a local buffer.
● Ring interfaces have three operating modes.
○ Repeater
○ Insert
○ Copy
● Repeater: the input bits are simply copied to output with a delay of 1 bit time.
● Insert: the interface breaks the connection b/w the input &output entering its own data
onto the ring.
● Copy: the interface or the station simply copies data into its local buffer as it is the
destined station.
● As bits have propagated around the ring & they come back, they are removed from the
ring by the sender.
Answer:
● This standard 802.4(Dirvin and Miller and IEEE, 1986) described a LAN called a token
bus.
● A simple system in which stations take turns sending a frame was introduced known
as a TOKEN BUS SYSTEM.
Operations of IEEE standard 802.4 LAN:
● The token bus is a linear tree shaped cable onto which stations are attached.
● Logically stations are organized into a ring with each station knowing the address of the
station to its left and right.
● Logical ring initialization the highest number station may send the first frame
● It passes permission to its immediate neighbour by sending the neighbor a special
control frame called a TOKEN.
● Only the token holder is permitted to transmit frames.
● Only one station at a time holds the token therefore no collision occurs.It uses a
broadcast medium for each station to receive frames.
Answer
Size of the frame format is 1572 Size of the frame format is 8202 Variable Size.
bytes. bytes.
Large frames.
Modems are not required Modems are required in this Modems are also required to it.
standard.
Ques 18 Define Fiber Distributed Data Interface (FDDI) in detail with the help of its
frame format.
Answer:
Frame Format:
It is similar to the format of a Token Ring Frame,this is one of the areas in which FDDI
borrows heavily from earlier LAN technologies,such as token ring.They can be as large as
4,500 bytes.
Ques 19 Brief about how line coding implemented in FDDI and describe its format.
Answer:
Ques 20 Discuss the issues in the data link layer and about its protocol on the basis of
layering principle.
Answer
The main job of the data link layer is to make the communication on the physical link reliable
& efficient.
● Issues:
– Framing
– Flow Control
– Error Control
– Synchronization
Framing:
Translation of physical layer’s raw bits into a larger aggregate (or) discrete units called
frames.
Here beginning and end of the data are marked to recognize the frame & used in
synchronization.
Synchronization:
● Receiver must know when the data begins & when it ends and also receiver should be
able to distinguish between each bit in the frame of data.
Flow Control:
● Refers to the mechanisms that make sure that the sending station cannot overwhelm
the receiving station.
● • Preventing the buffer overflow. Eg., Sliding Window.
Error Control:
OR
Answer
Sliding window protocols are data link layer protocols for reliable and sequential delivery of
data frames. The sliding window is also used in the Transmission Control Protocol.The term
sliding window refers to the imaginary boxes to hold frames. Sliding window method is also
known as windowing.The Sliding Window is a method of flow control in which a sender can
transmit the several frames before getting an acknowledgement. A single ACK acknowledges
multiple frames. Sliding Window refers to imaginary boxes at both the sender and receiver
end.
Working:
● The sender has a buffer called the sending window and the receiver has a buffer called
the receiving window.
● The size of the sending window determines the sequence number of the outbound
frames. If the sequence number of the frames is an n-bit field, then the range of
sequence numbers that can be assigned is 0 to 2𝑛−1. Consequently, the size of the
sending window is 2𝑛−1. Thus in order to accommodate a sending window size of
2𝑛−1, a n-bit sequence number is chosen.
● The sequence numbers are numbered as modulo-n. For example, if the sending
window size is 4, then the sequence numbers will be 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, and so
on. The number of bits in the sequence number is 2 to generate the binary sequence
00, 01, 10, 11.
● The size of the receiving window is the maximum number of frames that the receiver
can accept at a time. It determines the maximum number of frames that the sender can
send before receiving acknowledgment.
Ques 22 Discuss stop and wait technique for flow control.
Answer
● In the Stop-and-wait method, the sender waits for an acknowledgement after every
frame it sends.
● When acknowledgement is received, then only the next frame is sent.
● The process of alternately sending and waiting for a frame continues until the sender
transmits the EOT (End of transmission) frame.
● sender transmits one packet, then stops and waits
● receiver transmits a special packet, an acknowledgment (ack), whenever it gets a data
packet
● once the sender gets the ack, it transmits the next data packet
● if the sender does not get the ack within a certain time, it retransmits the packet
Central Idea:
In this method the message is broken into multiple frames, and the receiver indicates its
readiness to receive a frame of data. The sender waits for a receipt acknowledgement (ACK)
after every frame for a specified time (called a time out).
Here stop and wait means, whatever the data that sender wants to send, he sends the data to
the receiver. After sending the data, he stops and waits until he receives the
acknowledgement from the receiver. The stop and wait protocol is a flow control protocol
where flow control is one of the services of the data link layer.
Answer:
Advantages of stop-and-wait:
● Accurate
● Very simple
● Easy to implement
Disadvantages of stop-and-wait:
● The main disadvantage of this method is that it is inefficient. It makes the transmission
process slow.
● Fairly slow: the sender can send at most one new packet per RTT
● Not robust: if the ack can get lost, when the receiver gets a packet, the receiver cannot
tell if it is a retransmission or a new packet
● To deal with the last problem, must distinguish new packets from retransmissions
OR
Answer
OR
Answer:
In Go-Back-N ARQ, the frames are numbered sequentially as Go-Back-N ARQ sends the
multiple frames at a time that requires the numbering approach to distinguish the frame from
another frame, and these numbers are known as the sequential numbers.Here,N is the
sender's window size. Suppose we say that Go-Back-3, which means that the three frames
can be sent at a time before expecting the acknowledgment from the receiver.
Principle followed:
The multiple frames can be sent before receiving the acknowledgment of the first frame. If we
have five frames and the concept is Go-Back-3, which means that the three frames can be
sent, i.e., frame no 1, frame no 2, frame no 3 can be sent before expecting the
acknowledgment of frame no 1.
Step1: The sender will send the first four frames to the receiver,i.e.0,1,2,3 and now the sender
is expected to receive the acknowledgement of the 0th frame.
Ques 26 Illustrate the performance issues for Go-back-N data link protocol.
Answer
Ques 27 Write a short note on selective repeat ARQ.
Answer
SRP works better when the link is very unreliable. Because in this case, retransmission tends
to happen more frequently, selectively retransmitting frames is more efficient than
retransmitting all of them. SRP also requires a full duplex link. backward acknowledgements
are also in progress.
Ques 28 Compare two data link layer protocols: Go-back-N and selective repeat in
terms of flow control, error recovery and packet loss.
Answer
Sender window size of Go-Back-N Protocol Sender window size of the selective Repeat protocol is
is N. also N.
It detects and controls the error during It detects and corrects the error during transmission of
transmission of packets. packets.
If a packet is lost during transmission then it If a packet is lost during transmission then it discards
discards all the packets after receiving NAK only the packet which is lost and continues to send
acknowledgement for the lost packet. other packets.
Ques 29 Consider the use of 10 K-bit size frames on a 10Mbps satellite channel with
270 ms delay. What is the link utilization for stop and wait ARQ technique assuming
P=10-3?
Answer
= 1 msec
OR
Answer
In reliable full - duplex data transmission, the technique of hooking up acknowledgments onto
outgoing data frames is called piggybacking.
Three principles:
● If station X has both data and acknowledgment to send, it sends a data frame with the
ack field containing the sequence number of the frame to be acknowledged.
● If station X has only an acknowledgment to send, it waits for a finite period of time to
see whether a data frame is available to be sent. If a data frame becomes available,
then it piggybacks the acknowledgement with it. Otherwise, it sends an ACK frame.
● If station X has only a data frame to send, it adds the last acknowledgement with it.
Station Y discards all duplicate acknowledgments. Alternatively, station X may send the
data frame with the ack field containing a bit combination denoting no acknowledgment.
Answer
There are random single bit errors in asynchronous or synchronous mode of transmission and
burst error occurs in a group of continuous bits. The most widely used error-detecting codes
are the parity, block sum check, and the cyclic redundancy check (CRC) codes.
Types of errors:
Single Bit: The only one bit of a given data unit is changed from 1 to 0 or from 0 to 1,the
message which is sent is corrupted as single-bit, i.e 0 bit is changed to 1.
Single-Bit Error Does not appear more likely in Serial Data Transmission.
For example, Sender sends the data at 10 Mbps, this means that the bit lasts only for 1s and
for a single-bit error to occur, a noise must be more than 1s.
Single-Bit Error mainly occurs in Parallel Data Transmission. For example, if eight wires are
used to send the eight bits of
The term burst error means that two or more bits in the data unit have changed from 0 to 1 or
vice-versa. Note that burst error doesn’t necessarily mean that error occurs in consecutive
bits. The length of the burst error is measured from the first corrupted bit to the last corrupted
bit. Some bits in between may not be corrupted.
Burst errors are mostly likely to happen in serial transmission. The duration of the noise is
normally longer than the duration of a single bit, which means that the noise affects data it
affects a set of bits.
Answer
The parity bit is only suitable for detecting errors; it cannot correct any errors, as there is no
way to determine which particular bit is corrupted. The data must be discarded entirely, and
re-transmitted from scratch. On a noisy transmission medium, successful transmission can
therefore take a long time, or even never occur.
Method:
The parity check is done by adding an extra bit, called parity bit, to the data to make the
number of 1s either even or odd depending upon the type of parity. The parity check is
suitable for single bit error detection only. The two types of parity checking are 1. Even Parity
− Here the total number of bits in the message is made even. 2. Odd Parity− Here the total
number of bits in the message is made odd.
Ques 33 Explain the concept of checksum. How is error detected using the checksum
byte?
Answer
At the Sender side, the data is divided into equal subunits of n bit length by the checksum
generator. This bit is generally of 16-bit length. These subunits are then added together using
one’s complement method. This sum is of n bits. The resultant bit is then complimented. This
complemented sum which is called checksum is appended to the end of original data unit and
is then transmitted to Receiver.
The Receiver after receiving data + checksum passes it to checksum checker. Checksum
checker divides this data unit into various subunits of equal length and adds all these
subunits. These subunits also contain checksum as one of the subunits.
Answer
Cyclic Redundancy Check (CRC) An error detection mechanism in which a special number is
appended to a block of data in order to detect any changes introduced during storage (or
transmission). The CRe is recalculated on retrieval (or reception) and compared to the value
originally transmitted, which can reveal certain types of error. For example, a single corrupted
bit in the data results in a one-bit change in the calculated CRC, but multiple corrupt bits may
cancel each other out.
A CRC is derived using a more complex algorithm than the simple CHECKSUM, involving
MODULO ARITHMETIC (hence the ‘cyclic’ name) and treating each input word as a set of
coefficients for a polynomial.
Advantages:
Answer
2. Appending the CRC to the end of the data unit should result in the bit sequence which is
exactly divisible by the divisor.
Ques 36 Describe hamming code. How is it used for error detection and correction?
Illustrate with the help of suitable example.
OR
Answer
● The Hamming Code is simply the use of extra parity bits to allow the identification of an
error. Write the bit positions starting from 1 in binary form (1, 10, 11, 100, etc). All the bit
positions that are a power of 2 are marked as parity bits (1, 2, 4, 8, etc). All the other bit
positions are marked as data bits.
● Hamming code is a set of error correction codes that can be used to detect and correct
bit errors that can occur when computer data is moved or stored.
● Hamming code makes use of the concept of parity and parity bits that are added to
data so that the validity of the data can be checked when it is read or after it has been
received in a data transmission.
● Using more than one parity bit an error correction code cannot only identify a single bit
error in the data unit, but also its location in the data unit.
Working:
Suppose a binary data 1001101 is to be transmitted. To implement hamming code for this,
following steps are used:
1. Calculating the number of redundancy bits required. Since number of data bits is 7, the
value of r is calculated as
2r > m + r + 1
24 > 7 + 4 + 1
2. Determining the positions of various data bits and redundancy bits. The various r bits are
placed at the position that corresponds to the power of 2 i.e. 1, 2, 4, 8
Ques 37 Given a 10-bit sequence 1010011110 and a divisor of 1011. Find the CRC.
check your answer.
The CRC or the cyclic redundancy check is a checksum algorithm that detects the
inconsistency of data, that is the bit errors during the data transmission.
=x9 + x
6 + x² + x + 1 + 1/x³+x+1
=1
Ques 38 Sketch the Manchester and differential Manchester encoding for the bit stream
0001110101.
Answer
Ques 39 What is hamming code? Calculate the hamming code for the following message
string: 1100101 with each and every step explained clearly.
Answer
The Hamming Code is simply the use of extra parity bits to allow the identification of an error.
Unit 3
Answer
● Routing: When a packet reaches the router's input link, the router will move the packets
to the router's output link. For example, a packet from S1 to R1 must be forwarded to
the next router on the path to S2.
● Logical Addressing:The network layer adds a header to the packet which includes the
logical addresses of both the sender and the receiver.
● Internetworking: This is the main role of the network layer that provides the logical
connection between different types of networks.
● Fragmentation: The fragmentation is a process of breaking the packets into the
smallest individual data units that travel through different networks.
Answer
The host sends the packet to the nearest router. This packet is stored there until it has fully
arrived once the link is fully processed by verifying the checksum then it is forwarded to the
next router till it reaches the destination. This mechanism is called “Store and Forward packet
switching.”
2. Services provided to Transport Layer:
Through the network/transport layer interface, the network layer transfers it’s services to the
transport layer.
Packets are termed as “datagrams” and corresponding subnets as “datagram subnets”. When
the message size that has to be transmitted is 4 times the size of the packet, then the network
layer divides into 4 packets and transmits each packet to the router via. a few protocol.Each
data packet has destination address and is routed independently irrespective of the packets.
4. Implementation of Connection Oriented service:
To use a connection-oriented service, first we establish a connection, use it and then release
it. In connection-oriented services, the data packets are delivered to the receiver in the same
order in which they have been sent by the sender.
OR
What is adaptive routing algorithm? Explain various types of adaptive routing algorithm.
Answer
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 network 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
network uses virtual circuits internally, routing decisions are made only when a
new virtual circuit is being set up. Thereafter, data packets just follow the already
established route. The latter case is sometimes called session routing because a
route remains in force for an entire session (e.g., while logged in over a VPN).
1. Adaptive(dynamic)
1. Changes routes dynamically
2. Gather information at runtime
1. Locally
2. From adjacent routes
3. From all other routers
3. Change routes
1. When load changes
2. When topology changes
● If you apply the optimality principle then you can form a tree by taking the optimal path
from every other router to a single router, B.
● The tree is rooted at B. Since it is a tree you don't have loops, so you know that each
frame will be delivered in a finite number of hops.
● Of course finding the set of optimal trees is a lot harder in practice than in theory, but it
still provides a goal for all real routing algorithms.
● 1.) Discover your neighbors and learn their addresses.(Sending “hello” packet on each
point to point line.Destination node replies with its address.)
● 2.) Measure the cost (delay) to each neighbor.(send an “echo” packet
● 3.) Construct a packet containing all this information
● 4.) Send this packet to all other routers.
● 5.) Compute the shortest path to every other router.
Answer:
It occurs when a router uses a manually A process where a router can forward data via a different
configured routing entry rather than route or given destination based on the current conditions
information from a dynamic routing traffic of the communication circuits within a work
The network administrator manually adds The routes are found automatically according to the
the routes in the routing table changes in the network
Ques 5 What is meant by unicast and multicast routing with suitable diagrams?
Answer
Routing Table: A routing table can be either static or dynamic. A static table is one with
manual
entries. A dynamic table is one that is updated automatically when there is a change
procedures that lets routers in the Internet inform each other of changes.
There are two kinds of routing protocols available to route unicast packets:
Unicast routing protocols use graphs while Multicast routing protocols use trees, i.e. spanning
tree to avoid loops. The optimal tree is called the shortest path spanning tree.
OR
Answer
Unicast(delivers a message to a single specific node using a one-to-one association between
a sender and destination)
There are two kinds of routing protocols available to route unicast packets:
Ques 7 Explain distance vector routing algorithm and how it updates the routing tables
with the help of example.
Answer
Each router prepares its routing table using its local knowledge.
Step 2:
● Each router exchanges its distance vector obtained in Step-01 with its neighbors.
● After exchanging the distance vectors, each router prepares a new routing table.
Answer
Answer
Let G be a directed graph with n vertices V1, V2, V3 ...... Vn. Suppose G = (V, E, We) is
weighted graph. i.e., each edge e in G is assigned a non- negative number, we called the
weight or length of the edge e. Consider a starting vertices. Dijstra’s algorithm will find the
weight or length to each vertex from the source vertex.
Answer:
When the link goes down then the B-C entry in B's table will contain infinite value ,but for the
rest of the nodes,it will not be infinite immediately,it will take many rounds of transfer to finally
stabilize the nodes,which is known as the count to infinity problem.
The main problem with Distance Vector Routing (DVR) protocols is Routing Loops, since
Bellman-Ford Algorithm cannot prevent loops. This routing loop in the DVR network causes
Count to Infinity Problem. Routing loops usually occur when any interface goes down or
two-routers send updates at the same time.
Example:
Imagine a network with a graph as shown above in figure 4.8.
As you see in this graph, there is only one link between A and the other parts of the network.
After a specific amount of time, routers exchange their tables, and so B receives C's routing
table.
Since C doesn't know what has happened to the link between A and B, it says that it has a
link to A with the weight of 2 (1 for C to B, and 1 for B to A -- it doesn't know B has no link to
A).
B receives this table and thinks there is a separate link between C and A, so it corrects its
table and changes infinity to 3 (1 for B to C, and 2 for C to A, as C said).
When C receives B's routing table, it sees that B has changed the weight of its link to A from 1
to 3, so C updates its table and changes the weight of the link to A to 4 (1 for C to B, and 3 for
B to A, as B said).
This process loops until all nodes find out that the weight of link to A is infinity.
For example, in this case, C shouldn't send any information to B about A, because B is the
only way to A.
OR
OR
Answer
● Problem: When too many packets are transmitted through a network, congestion
occurs At very high traffic, performance collapses completely, and almost no packets
are delivered
● Causes: Bursty nature of traffic is the root cause → When part of the network can no
longer cope with a sudden increase of traffic, congestion builds upon. Other factors,
such as lack of bandwidth, ill-configuration and slow routers can also bring up
congestion.
● Solution: congestion control, and two basic approaches – Open-loop: try to prevent
congestion occurring by good design – Closed-loop: monitor the system to detect
congestion, pass this information to where action can be taken, and adjust system
operation to correct the problem (detect, feedback and correct).
● Congestion:A state occurs in the network layer when the message traffic is so heavy
that it slows down network response time.
● Effects:
● As delay increases, performance decreases.
● If delay increases, retransmission occurs, making the situation
worse.
Ques 12 What is the difference between open-loop congestion control and closed-loop
congestion control?
Answer
Ques 13 Define traffic shaping. Elaborate leaky bucket algorithm used for congestion
control.
OR
What is the congestion in network layer? Discuss at least one algorithm used for
congestion control.
OR
Answer
Imagine a bucket with a small hole in the bottom.No matter at what rate water enters the
bucket, the outflow is at constant rate.When the bucket is full with water additional water
entering spills over the sides and is lost.
Similarly, each network interface contains a leaky bucket and the following steps are involved
in leaky bucket algorithm:
1. When the host wants to send a packet, the packet is thrown into the bucket.
2. The bucket leaks at a constant rate, meaning the network interface transmits packets
at a constant rate.
3. Bursty traffic is converted to uniform traffic by the leaky bucket.
4. In practice the bucket is a finite queue that outputs at a finite rate.
Advantages:
● Token independent
● Packets are transmitted continuously
● It sends the packet at constant rate Input rate can differ but output rate will be constant
Disadvantages:
Ques 14 Write a short note on the token bucket algorithm. What are the limitations of
the leaky bucket algorithm?
Answer
The leaky bucket algorithm enforces output pattern at the average rate, no matter how bursty
the traffic is. So in order to deal with the bursty traffic we need a flexible algorithm so that the
data is not lost. One such algorithm is the token bucket algorithm.
Steps include:
Que 15 What do you mean by congestion control and QoS/ what are the parameters of QoS?
Explain.
Answer:
● Problem: When too many packets are transmitted through a network, congestion
occurs At very high traffic, performance collapses completely, and almost no packets
are delivered
● Causes: Bursty nature of traffic is the root cause → When part of the network can no
longer cope with a sudden increase of traffic, congestion builds upon. Other factors,
such as lack of bandwidth, ill-configuration and slow routers can also bring up
congestion.
● Solution: congestion control, and two basic approaches – Open-loop: try to prevent
congestion occurring by good design – Closed-loop: monitor the system to detect
congestion, pass this information to where action can be taken, and adjust system
operation to correct the problem (detect, feedback and correct).
● Congestion:A state occurs in the network layer when the message traffic is so heavy
that it slows down network response time.
● Effects:
● As delay increases, performance decreases.
● If delay increases, retransmission occurs, making the situation
worse.
The main focus of congestion control and quality of service is data traffic. In congestion
control we try to avoid traffic congestion. In quality of service, we try to create an appropriate
environment for the traffic. So, before talking about congestion control and quality of service,.
● Reliability
● Security
● Delay
● Availability
Answer
Aim:To find out the MAC address of the destination that allows us to communicate with other
devices. In this case, the ARP is actually required as it converts the IP address to a physical
address.
Working of ARP:
Arping probes hosts on the examined network link by sending Link Layer frames using the
Address Resolution Protocol (ARP) request method addressed to a host identified by its MAC
address of the network interface.
Answer
Reverse ARP (RARP) is a networking protocol used by the client system in a local area
network (LAN) to request its IPv4 address from the ARP gateway router table. A table is
created by the network administrator in the gateway-router that is used to find out the MAC
address to the corresponding IP address.
Working of RARP:
The RARP is on the Network Access Layer and is employed to send data between two points
in a very network.The client broadcasts a RARP request with an Ethernet broadcast address
and with its own physical address. The server responds by informing the client its IP address.
Answer
● Connectivity
● Reliability
● Network Management
● Flexibility
Answer
An internet protocol (IP) address allows computers to send and receive information.
There are four types of IP addresses: public, private, static, and dynamic.
An IP address allows information to be sent and received by the correct parties, which means
they can also be used to track down a user's physical location.
Internet Protocol (IP) provides connectionless packet delivery and “best-effort” quality of
service.Every host interface has its own IP address.Routers have multiple interfaces, each
with its own IP address
OR
Answer
Every device that connects to the Internet is assigned a unique IP (Internet Protocol) address,
enabling data sent over the Internet to reach the right device out of the billions of devices
connected to the Internet. While computers read IP addresses as binary code (a series of 1s
and 0s), IP addresses are usually written as a series of alphanumeric characters.
Significance of Subnetting:
The way IP addresses are constructed makes it relatively simple for Internet routers to find
the right network to route data into. However, in a Class A network (for instance), there could
be millions of connected devices, and it could take some time for the data to find the right
device. This is why subnetting comes in handy: subnetting narrows down the IP address to
usage within a range of devices.
Because an IP address is limited to indicating the network and the device address, IP
addresses cannot be used to indicate which subnet an IP packet should go to. Routers within
a network use something called a subnet mask to sort data into subnetworks.
Answer
An internet protocol (IP) address allows computers to send and receive information. There are
four types of IP addresses: public, private, static, and dynamic. An IP address allows
information to be sent and received by the correct parties, which means they can also be
used to track down a user's physical location.
Types of IP Addresses:
1. A public IP address is an address where one primary address is associated with your
whole network. In this type of IP address, each of the connected devices has the same
IP address.
Answer
IP header includes many relevant information including Version Number, which, in this
context, is 4. Other details are as follows −
Answer
Traffic Class (8-bits): These 8 bits are divided into two parts. The most significant 6 bits are
used for Type of Service to let the Router Known what services should be provided to this
packet. The least significant 2 bits are used for Explicit Congestion Notification (ECN).
Flow Label (20-bits): This label is used to maintain the sequential flow of the packets
belonging to a communication. The source labels the sequence to help the router identify that
a particular packet belongs to a specific flow of information. This field helps avoid re-ordering
of data packets. It is designed for streaming/real-time media.
Payload Length (16-bits): This field is used to tell the routers how much information a
particular packet contains in its payload. Payload is composed of Extension Headers and
Upper Layer data. With 16 bits, up to 65535 bytes can be indicated.
Next Header (8-bits): This field is used to indicate either the type of Extension Header, or if
the Extension Header is not present then it indicates the Upper Layer PDU. The values for the
type of Upper Layer PDU are same as IPv4’s.
Hop Limit (8-bits): This field is used to stop packet to loop in the network infinitely. This is
same as TTL in IPv4. The value of Hop Limit field is decremented by 1 as it passes a link
(router/hop). When the field reaches 0 the packet is discarded.
Source Address (128-bits): This field indicates the address of originator of the packet.
Destination Address (128-bits): This field provides the address of intended recipient of the
packet
Answer
Dividing the network into smaller contiguous networks or subnets is called subnetting.
Example:
Suppose we take a network of class A. So, in class A, we have 2²⁴ hosts. So managing such
a large number of hosts is tedious. So if we divide this large network into the smaller network
then maintaining each network would be easy.
In the 1st subnet network(S1), we have a total of 126 hosts only because the first and last IP
address is reserved for the network ID and the Direct Broadcast Address respectively.
Similarly, in the 2nd subnet network, we have 126 hosts.
Ques 25 What are deficiencies of IPv4? How IPv6 was modified to overcome these
deficiencies?
Answer
Limitations of IPv4:
● The lack of address space - the number of different devices connected to the Internet
grows exponentially, and the size of the address space is quickly depleted.
● Service support is not qualitative: Anything you buy, you expect a high quality of
support, but in IPv4 some network applications when not running smoothly are not
supported.
● IP addresses centralized in US: Since the internet was invented in the US, a large pool
(nearly 50%) of IP addresses were centralized and reserved for the US only.
● Growth of the internet worldwide has increased demand for IPv4s but lack of supply of
IPv4 addresses has caused companies to squander to acquire IPv4s.
● Weak protocol extensibility - The insufficient size of the IPv4 header, which does not
accommodate the required number of additional parameters;
IPv6 was introduced to take place of IPv4 and has many advantages over IPv4 (
disadvantages of IPv4), namely:
Ques 26 Perform the subnetting of the following IP address 160.11.X.X. Original subnet
mask 255.255.0.0 and number of subnet 6 (six).
Answer
Ques 27 Give an IP address. How will you extract its netid and hostid and compare IPv4
and IPv6 with frame format.
Answer
Ques 28 What is meant by fragmentation? Is fragmentation needed in concatenated
virtual circuit internets, or in any datagram system?
OR
Answer
The fragmentation is a process of breaking the packets into the smallest individual data units
that travel through different networks.
A datagram can travel through different networks. Each router de-encapsulates the IPv4
datagram from the frame it receives, processes it, and then encapsulates it in another frame.
The format and size of the received frame depend on the protocol used by the physical
network through which the frame has just traveled. The format and size of the sent frame
depend on the protocol used by the physical network through which the frame is going to
travel. For example, if a router connects a LAN to a WAN, it receives a frame in the LAN
format and sends a frame in the
WAN format.
Example:
Ques 29 What is transmission time of a packet sent by a station if the length of the
packet is 2 million bytes and the bandwidth of the channel is 300 kbps.
Answer
=6.67s
Ques 30
I. Find the class of each address
1. 140.213.10.80 b. 52.15.150.11
1. 4 F: : A 2 3 4: 2 b. 52 F : : 1 2 3 4 : 2 2 2 2
Answer:
So,
Answer
Interconnected devices are physical objects that can send and receive information or data to
and from the internet. Some interconnected devices can also send information or commands
to other products. Common interconnected devices include: smart phones, computers,
laptops and tablets.
● Hub.
● Switch.
● Router.
● Bridge.
● Gateway.
● Modem.
● Repeater.
● Access Point.
Hubs are networking devices operating at a physical layer of the OSI model that are used to
connect multiple devices in a network. They are generally used to connect computers in a
LAN. ... A computer which intends to be connected to the network is plugged in to one of
these ports.
Switches are networking devices operating at layer 2 or a data link layer of the OSI model.
They connect devices in a network and use packet switching to send, receive or forward data
packets or data frames over the network. A switch has many ports, to which computers are
plugged in.
A router is a networking device that forwards data packets between computer networks.
Routers perform the traffic directing functions on the Internet. Then, using information in its
routing table or routing policy, it directs the packet to the next network on its journey.
A network bridge is a computer networking device that creates a single, aggregate network
from multiple communication networks or network segments.
Routing allows multiple networks to communicate independently and yet remain separate,
whereas bridging connects two separate networks as if they were a single network.
A gateway is a node (router) in a computer network, a key stopping point for data on its way
to or from other networks.In a workplace, the gateway is the computer that routes traffic from
a workstation to the outside network that is serving up the Web pages.
OR
Answer
The transport layer is responsible for process-to-process delivery. The User Datagram
Protocol (UDP) is called a connectionless, unreliable transport protocol. It does not add
anything to the services of IP except to provide process-to-process communication instead of
host-to- host communication.
TCP provides process to process communication, i.e, the transfer of data takes place
between individual processes executing on end systems. This is done using port numbers or
port addresses. Port numbers are 16 bit long that help identify which process is sending or
receiving data on a host.
End to end delivery can be accomplished in two ways:
1. Connection oriented
2. Connectionless
Answer
● Accepting data from Session layer, split it into segments and send to the network layer.
● End to end delivery of the packet
● Ensure correct delivery of data with efficiency.
● Isolate upper layers from the technological changes.
● Error control and flow control.
● Connection Management
Ques 3 Enumerate how the transport layer ensures that the complete message arrives at
the destination and in the proper order.
Aim :
It ensures the whole message arrives intact and in order ensures both error control and flow
control at the source to destination level.
It breaks the message into small units so that they are handled more efficiently by the network
layer and ensures that the message arrives in order by checking error and flow control.
Error Control: Performed end to end in this layer to ensure that the complete message arrives
at the receiving transport layer without any error,done through retransmission
Answer
Answer
UDP header is 8-bytes fixed and simple header, while for TCP it may vary from 20 bytes to 60
bytes. First 8 Bytes contain all necessary header information and the remaining part consist of
data. UDP port number fields are each 16 bits long, therefore range for port numbers defined
from 0 to 65535; port number 0 is reserved. Port numbers help to distinguish different user
requests or process
1. Source Port : Source Port is 2 Byte long field used to identify port number of source.
2. Destination Port : It is 2 Byte long field, used to identify the port of destined packet.
3. Length : Length is the length of UDP including header and the data. It is 16-bits field.
4. Checksum : Checksum is 2 Bytes long field. It is the 16-bit one’s complement of the
one’s complement sum of the UDP header, pseudo header of information from the IP
header and the data, padded with zero octets at the end (if necessary) to make a
multiple of two octets.
Answer
Answer
Ques 8 Explain the three-way handshaking protocol to establish the transport level
connection.
Answer
TCP provides reliable communication with something called Positive Acknowledgement with
Retransmission(PAR). The Protocol Data Unit(PDU) of the transport layer is called segment.
Now a device using PAR resends the data unit until it receives an acknowledgement. If the
data unit received at the receiver’s end is damaged(It checks the data with checksum
functionality of the transport layer that is used for Error Detection), then the receiver discards
the segment. So the sender has to resend the data unit for which positive acknowledgement
is not received. You can realize from the above mechanism that three segments are
exchanged between sender(client) and receiver(server) for a reliable TCP connection to be
established.
Steps used to establish connection between Host P and Q by 3 way handshake are:
● Step 1 (SYN) : In the first step, client wants to establish a connection with server, so it
sends a segment with SYN(Synchronize Sequence Number) which informs server that
client is likely to start communication and with what sequence number it starts
segments with
● Step 2 (SYN + ACK): Server responds to the client request with SYN-ACK signal bits
set. Acknowledgement(ACK) signifies the response of segment it received and SYN
signifies with what sequence number it is likely to start the segments with
● Step 3 (ACK) : In the final part client acknowledges the response of server and they
both establish a reliable connection with which they will start the actual data transfer
The steps 1, 2 establish the connection parameter (sequence number) for one direction and it
is acknowledged.
The steps 2, 3 establish the connection parameter (sequence number) for the other direction
and it is acknowledged.
Ques 9 Explain about the TCP header and working of TCP protocol and differentiate
between TCP and UDP with frame format.
Answer
Because UDP has a low-overhead, it has Because of TCP high-overhead, it has slow
faster transmission of data. transmission of data
UDP does not acknowledge receiving of the TCP is reliable, because it acknowledges the
data and does not resend lost data. Thus, it is received data and resends any lost data.
not reliable.
Suitable for applications that need fast,efficient Suitable for applications that require high reliability
transmission and reliability is less critical and transmission time is relatively less critical
Lossy Reliable
It never acknowledges the data receipt and TCP protocol follows the handshake process
hence there is no chance of re-transmission of between sender and receiver to acknowledge the
data. receipt of data packets in both directions. Thus this
offers the facility of retransmission of lost data
packets.
Ques 10 Draw the diagram of TCP header and explain the use of the following;
Answer
● Sequence Number –
32 bit field that holds the sequence number, i.e, the byte number of the first byte that is
sent in that particular segment. It is used to reassemble the message at the receiving
end if the segments are received out of order.
● Acknowledgement Number –
32 bit field that holds the acknowledgement number, i.e, the byte number that the
receiver expects to receive next. It is an acknowledgement for the previous bytes being
received successfully.
● Control flags –
These are 6 1-bit control bits that control connection establishment, connection
termination, connection abortion, flow control, mode of transfer etc. Their function is:
○ URG: Urgent pointer is valid
○ ACK: Acknowledgement number is valid( used in case of cumulative
acknowledgement)
○ PSH: Request for push
○ RST: Reset the connection
○ SYN: Synchronize sequence numbers
○ FIN: Terminate the connection
● Window size –
This field tells the window size of the sending TCP in bytes.
● Checksum –
This field holds the checksum for error control. It is mandatory in TCP as opposed to
UDP.
● Urgent pointer –
This field (valid only if the URG control flag is set) is used to point to data that is
urgently required that needs to reach the receiving process at the earliest. The value of
this field is added to the sequence number to get the byte number of the last urgent
byte.
Ques 11 Explain TCP congestion control algorithm in internet. What is TCP segment
header? Also, discuss TCP connection management.
Answer
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.
Congestion: the load on the network is greater than the capacity of the
network.Congestion control: the mechanisms to control the congestion and keep the
load below the capacity
● As a result, retransmission of packets from the sources increases the congestion
further. In this situation, the Transport layer provides Congestion Control in different
ways.
● It uses open loop congestion control to prevent the congestion and closed loop
congestion control to remove the congestion in a network once it occurs. TCP provides
AIMD- additive increase multiplicative decrease, leaky bucket technique for congestion
control.
● Packet loss typically results from buffer overflow in routers as the network becomes
congested.
Ques 12 Why TCP is preferred over UDP in some applications? Explain the reasons and
also mention those applications.
Answer
● TCP is an ideal choice, and even it has associated overhead, Therefore, when most of
the overhead is in the connection, your application stays connected for any length of
time.
● UDP is ideal to use with multimedia like VoIP.
● Use TCP sockets when both client and server independently send packets at that time;
an occasional delay is acceptable. (e.g., Online Poker).
● You should use user UDP if both client and server may separately send packets, and
occasional delay is also not acceptable. (e.g., Multiplayer games).
Ques 13 Discuss the design issues of session layer. List the services provided by session
layer.
Answer
Answer
Answer
Answer
RPC ISSUES :
1. RPC Runtime:
RPC run-time system is a library of routines and a set of services that handle the network
communications that underlie the RPC mechanism. In the course of an RPC call, client-side
and server-side run-time systems’ code handle binding, establish communications over an
appropriate protocol, pass call data between the client and server, and handle
communications errors.
2. Stub:
● On the server side, the stub provides a similar interface between the run-time system
and the local manager procedures that are executed by the server.
3. Binding:
How does the client know who to call, and where the service resides?
The most flexible solution is to use dynamic binding and find the server at run time when the
RPC is first made. The first time the client stub is invoked, it contacts a name server to
determine the transport address at which the server resides.
● Naming:
● Locating:
1. A Server having a service to offer exports an interface for it. Exporting an interface
registers it with the system so that clients can use it.
Answer
1. Translation –
It is necessary that the information which is in the form of numbers, characters and
symbols needs to be changed to the bit streams. The presentation layer handles the
different encoding methods used by different machines .It manages the translation of
data between the format the network requires and the computer.
2. Encryption –
The data encryption at the transmission end as well as the decryption at the receiver
end is managed by the presentation layer.
3. Compression –
In order to reduce the number of bits to be transmitted, the presentation layer performs
the data compression. It increases efficiency in case of multimedia files such as audio,
video etc.
Network channels and components may be unreliable, resulting in loss of bits while
data transfer. So, an important design issue is to make sure that the information
transferred is not distorted.
1. Flow Control
If the rate at which data is produced by the sender is higher than the rate at which data
is received by the receiver, there are chances of overflowing the receiver. So, a proper
flow control mechanism needs to be implemented.
Ques 18 Describe data compression. What are the techniques/ types of data
compression?
Answer
1. Lossy
● Lossy Compression refers to data compression techniques in which some amount of
data is lost.
● Lossy compression technologies attempt to eliminate redundant or unnecessary
information.
● If the decompressed information need not be an exact replica of the original information
but something very close, we can use a lossy data compression method.
● It reduces a file by permanently eliminating certain information, especially redundant
information.
1. Lossless
● Lossless compression refers to data compression techniques in which no data is lost.
● For most types of data, lossless compression techniques can reduce the space needed
by only about 50%.
● For greater compression, one must use a lossy compression technique
1. Digital audio
2. Audio compression
3. Streaming audio
Answer
1. Digital Audio
Digital audios are created when the characteristics of sound waves are represented using a
number – a process referred to as Digitizing.
Every nth fraction of a second, a sample of a sound is taken & stored as digital information in
bits and bytes.
The quality of digital recording depends on the how often the samples are taken i.e. Higher
the sampling rate the better is the quality of sound.
1. Audio Compression
● Audio is the sound system that comes with or can be added to a computer.
● An audio file is a record of captured sound that can be played back.
● An audio card contains a special built-in processor and memory for processing audio
files and sending them to speakers in the computer.
● Sound is a sequence of naturally analog signals that are converted to digital signals by
the audio card, using a microchip called an analog-to-digital converter (ADC).
● When sound is played, the digital signals are sent to the speakers where they are
converted back to analog signals that generate varied sound
Audio Compression
● Audio compression is a form of data compression designed to reduce the size of audio
files.
● There is a conditions on this definition :
○ the audio file must still be playable after compression, without decompressing it
to original size when you want to play it (for example with WinRAR).
○ If the file is compressed 'too much' there will be loss of quality. The compression
is done with a thing called a codec. This is an aggregation of the words:
compressor and decompressor.
○ This codec is a special algorithm to reduce the size.
1. Streaming audio
● The continuous download of a compressed audio or video file, which can be heard or
viewed on the user’s workstation
● Real-Time Protocol (RTP) and Real-Time Streaming Protocol (RTSP) support
streaming audio and video
● Streaming audio and video consume a large amount of network resources
Answer
● Step 1: The input image is divided into a small block which has 8x8 dimensions. This
dimension is summed up to 64 units. Each unit of the image is called a pixel.
● Step 2: JPEG uses the [Y,Cb,Cr] model instead of using the [R,G,B] model. So in the
2nd step, RGB is converted into YCbCr.
● Step 3: After the conversion of colors, it is forwarded to DCT. DCT uses a cosine
function and does not use complex numbers. It converts information?s which are in a
block of pixels from the spatial domain to the frequency domain.
● Step 4: Humans are unable to see important aspects of the image because they are
having high frequencies. The matrix after DCT conversion can only preserve values at
the lowest frequency to a certain point. Quantization is used to reduce the number of
bits per sample.
● Step 5: The zigzag scan is used to map the 8x8 matrix to a 1x64 vector. Zigzag
scanning is used to group low-frequency coefficients to the top level of the vector and
the high coefficient to the bottom. To remove the large number of zero in the quantized
matrix, the zigzag matrix is used.
● Step 6: Next step is vectoring, the different pulse code modulation (DPCM) is applied to
the DC component. DC components are large and vary but they are usually close to the
previous value. DPCM encodes the difference between the current block and the
previous block.
● Step 7: In this step, Run Length Encoding (RLE) is applied to AC components. This is
done because AC components have a lot of zeros in it. It encodes in pair of (skip,
value) in which skip is non zero value and value is the actual coded value of the non
zero components.
● Step 8: In this step, DC components are coded into Huffman.
Ques 22 Define cryptography with the help of block diagram of symmetric and
asymmetric key cryptography.
Answer
Symmetric key cryptography is any cryptographic algorithm that is based on a shared key that
is used to encrypt or decrypt text/ciphertext, in contract to asymmetric key cryptography,
where the encryption and decryption keys are different.
Symmetric encryption is generally more efficient than asymmetric encryption and therefore
preferred when large amounts of data need to be exchanged.
Examples for symmetric key cryptography include AES, DES, and 3DES.
Asymmetric Encryption uses two distinct, yet related keys. One key, the Public Key, is used
for encryption and the other, the Private Key, is for decryption. As implied in the name, the
Private Key is intended to be private so that only the authenticated recipient can decrypt the
message.
Working:
At the heart of Asymmetric Encryption lies a cryptographic algorithm. This algorithm uses a
key generation protocol (a kind of mathematical function) to generate a key pair. Both the
keys are mathematically connected with each other. This relationship between the keys differs
from one algorithm to another.
Answer
Answer
RSA algorithm is an asymmetric cryptography algorithm. Asymmetric actually means that it
works on two different keys i.e. Public Key and Private Key.
RSA algorithm is a public key encryption technique and is considered as the most secure way
of encryption.
Features of RSA:
● The RSA algorithm is a popular exponentiation in a finite field over integers including
prime numbers.
● The integers used by this method are sufficiently large making it difficult to solve.
● There are two sets of keys in this algorithm: private key and public key.
Algorithm:
N=p*q
Consider number e as a derived number which should be greater than 1 and less than (p-1)
and (q-1). The primary condition will be that there should be no common factor of (p-1) and
(q-1) except 1
The specified pair of numbers n and e forms the RSA public key and it is made public.
Encryption Formula
Consider a sender who sends the plain text message to someone whose public key is (n,e).
To encrypt the plain text message in the given scenario,syntax used:
C = Pe mod n
Decryption Formula
The decryption process is very straightforward and includes analytics for calculation in a
systematic approach. Considering receiver C has the private key d, the result modulus will be
calculated as −
Plaintext = Cd mod n
Ques 25 Explain data encryption standard algorithm and its working in detail.
Answer
● Data Encryption Standard (DES) is a block cipher algorithm that takes plain text in
blocks of 64 bits and converts them to ciphertext using keys of 48 bits. It is a symmetric
key algorithm, which means that the same key is used for encrypting and decrypting
data.
● Since it’s a symmetric-key algorithm, it employs the same key in both encrypting and
decrypting the data. If it were an asymmetrical algorithm, it would use different keys for
encryption and decryption
1. The process begins with the 64-bit plain text block getting handed over to an initial
permutation (IP) function.
2. The initial permutation (IP) is then performed on the plain text.
3. Next, the initial permutation (IP) creates two halves of the permuted block, referred to
as Left Plain Text (LPT) and Right Plain Text (RPT).
4. Each LPT and RPT goes through 16 rounds of the encryption process.
5. Finally, the LPT and RPT are rejoined, and a Final Permutation (FP) is performed on
the newly combined block.
6. The result of this process produces the desired 64-bit ciphertext.
Ques 26 Differentiate between the block cipher with transposition cipher.
Answer
A block of plain text is considered as a whole. Plain text is written down as a sequence.
Security of a block cipher depends on the design Can be made more secure by performing more
of the encryption function. than one transposition
Encryption process is slow here. Encryption process is fast here.
Plain text is broken into blocks and the algorithm Plain text is broken into letters and the algorithm
operates on each block independently operates on each letter independently.
Ques 27 Using the RSA public key cryptosystem with a=1, b=2 etc.
Answer
p=7,q=11
n=p*q = 77
Phi = (p-1)(q-1)=6*10=60
0<e<phi
Say e={13,17,19,23,29,31,37,41,43,47,53,59}
Taking e = 13
Ed mod phi =1
D = 13 mod 60
Answer
The transfer of voice signals using a packet switched network and the IP protocol Voice over
IP (VoIP) can be internal to a company (private Voip) or can be external using the Internet
VoIP consumes many resources and may not always work well, but can be cost-effective in
certain situations
Ques 29 What are the problems for full implementation of voice over IP? Did you think
we will stop using the telephone network very soon?
Answer
● The computer must always be available in on mode with the internet connected
● Even if any one of the entities i.e the computer or internet fails to work,the telephone
system will also not work.
● There may be some delay in the voice due to problems in the internet
● The connection may lose in the middle if the internet connection is disconnected
● It may be susceptible to attacks
● The susceptibility of phone service to power failure can also occur.
● The nature of IP makes it difficult to locate network users geographically and hence
emergency calls cannot be routed easily.
● No we will not stop using telephone networks
Ques 30 Compare and contrast TCP and RTP. Are both doing the same thing?
AKTU 2014-15, Marks 05
Answer
TCP is a connection-oriented protocol that means RTP is a network protocol which is used for
the communicating devices establish a connection delivering audio and video over networks.
before transmitting data and close the connection
after transmitting the data.
Not generally used for real time streaming Used for real time streaming
TCP and RTP: Transmission Control Protocol (TCP) and Real-Time Transport Protocol (RTP)
both are used to make communication between computers over the internet.
Ques 31 What is the total delay (latency) for a frame size of 10 million bits that is
being set up on link with 15 routers, each having queuing time of 2 μs and a processing
time of 1 μs? The length of the link is 3000 km. the speed of light inside the link 2 x 108
m/sec. The link has a bandwidth of 6 Mbps.
Answer
Ques 32 A rectangular wave-guide (a = 2cm, b=1 cm) filled with deionized water (μ =
1, ξ=81) operates at 3 GHz. Determine all propagating modes and corresponding cut-off
frequencies.
Answer
For a general transverse electric(TE) or transverse magnetic (TM) mode,the cut off frequency
is given as:
Cut off Frequency(in GHz) Cut off Frequency(in GHz)
Since the operating frequencies is 3 GHz,all the propagating modes and their cut off
frequencies are given below:
TE10 0.8333
TE01,TE20 1.667
TE11,TM11 1.863
TE21.TM21 2.357
TE30 2.500
Unit 5
Answer
The Application Layer is the seventh layer of the seven-layer OSI model. Application layer
interface directly interacts with the application and provides common web application
services. The application layer also makes a request to the presentation layer. Application
layer is the highest level of open systems, providing services directly for the application
process.
● Network Virtual terminal: An application layer allows a user to log on to a remote host.
To do so, the application creates a software emulation of a terminal at the remote host.
The user's computer talks to the software terminal, which in turn, talks to the host. The
remote host thinks that it is communicating with one of its own terminals, so it allows
the user to log on.
● File Transfer, Access, and Management (FTAM): An application allows a user to access
files in a remote computer, to retrieve files from a computer and to manage files in a
remote computer. FTAM defines a hierarchical virtual file in terms of file structure, file
attributes and the kind of operations performed on the files and their attributes.
● Addressing: To obtain communication between client and server, there is a need for
addressing. When a client makes a request to the server, the request contains the
server address and its own address. The server response to the client request contains
the destination address, i.e., client address. To achieve this kind of addressing, DNS is
used.
● Mail Services: An application layer provides Email forwarding and storage.
● Directory Services: An application contains a distributed database that provides access
for global information about various objects and services.
● Authentication: It authenticates the sender or receiver's message or both.
Answer:
FTP services generally run on both ports 20 and 21. Port 20 is used to transmit data flow
between the client and server, while port 21 is used to transmit control flow and is the
command to import to the ftp server. When data is streamed, the control flow is idle. When the
control flow, idle for a long time, the client's firewall, the session will be set to overtime, so
when a large amount of data through the firewall, there will be some problems. At this point,
although the file can be successfully transmitted, it can be broken by the firewall because of
the control session; the transfer can result in some errors.
Ques 3 How does FTP work? Differentiate between passive and active FTP.
Answer
Working of FTP:
FTP is a client-server protocol and it relies on two communication channels between the client
and the server.
Control Connection: The FTP client, for example, FileZilla or FileZilla Pro sends a connection
request usually to server port number 21. This is the control connection. It is used for sending
and receiving commands and responses. Typically a user needs to log on to the FTP server
for establishing the connection but there are some servers that make all their content
available without login. These servers are known as anonymous FTP.
Data Connection: For transferring the files and folder we use a separate connection called
data connection.
In this mode, the user connects from a In the situation,where the client can not accept a
random port(random port 1) on the FTP client connection like when blocked by a firewall, the
to port 21 of the server. passive mode has to be used.
Active FTP provides security to the FTP Passive FTP does not provide security to the FTP
server. server.
Active mode is not used as a default mode of Passive mode is used as a default mode of a
a browser. browser.
Client sends a random port number to the Client sends PASV command to the server.
server.
Active FTP may cause problems because of Passive FTP does not have connection issues from
firewalls firewalls.
1. MIME
2. TFTP
Answer
It is a development of the Internet email protocol that enables its users to exchange several
kinds of data files over the Internet, including images, audio, and video.
The MIME is required if the text in character sets other than the American Standard Code for
Information Interchange (ASCII). Virtually, all human-written Internet email and a fairly large
proportion of automated email is transmitted via Simple Mail Transfer Protocol (SMTP) in
MIME format.
● Following are the different kinds of data files that can be exchanged on the Internet
using MIME:
○ audio
○ images
○ text
○ video
○ Other application-specific data(it can be pdf, Microsoft word document, etc).
It is a simple high-level protocol for transferring data servers use to boot diskless
workstations, X-terminals, and routers by using User Data Protocol (UDP).
TFTP works differently than FTP (File Transfer Protocol) and HTTP (HyperText Transfer
Protocol). Although TFTP is also based in FTP technology, TFTP is an entirely different
protocol. Among the differences is that TFTP’s transport protocol uses UDP which is not
secure while FTP uses Transmission Control Protocol (TCP) to secure information.
TFTP was primarily designed to read or write files by using a remote server. However, TFTP
is a multi-purpose protocol that can be leveraged for an array of different tasks.
Answer
● 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.
● DNS is a protocol that can be used on different platforms.
● Domain Name Space is divided into different sections in the Internet: Generic domain,
country domain and inverse domain.
● 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.
● DNS has some protocols that allow the client and servers to communicate with each
other.
Ques 6 How does DNS perform data name resolution? What are the different types of
name servers? Mention the DNS message format for query and reply messages.
OR
Answer
● The message has a fixed 12-byte header followed by four variable-length fields.The
first 12 bytes is the header section, which has a number of fields.
● The identification is set by the client and returned by the server. It lets the client match
responses to requests .
● The 16-bit flags field is divided into numerous pieces
● The first field is a 16-bit number that identifies the query. This identifier is copied into
the reply message to a query, allowing the client to match received replies with sent
queries.
● These fields indicate the number of occurrences of the four types of data sections that
follow the header.
● This section includes (1) a name field that contains the name that is being queried, and
(2) a type field that indicates the type of questions being asked about the name
● The answer section contains the resource records for the name that was originally
queried. Recall that in each resource record there is the Type (for example, A, NS,
CNAME, and MX), the Value, and the TTL.
● The authority section contains records of other authoritative servers.
● The additional section contains other helpful records. For example, the answer field in a
reply to an MX query contains a resource record providing the canonical hostname of a
mail server.
Ques 7 Define DNS and its requirements. Explain the specific features of it.
Answer:
● 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.
● DNS is a protocol that can be used on different platforms.
● Domain Name Space is divided into different sections in the Internet: Generic domain,
country domain and inverse domain.
Requirements of DNS:
Specific Features:
● DNS contains support for caching the requests & for redundancy.Most network
operating systems support configuration of primary , secondary and tertiary DNS
servers , each of which can service initial requests from clients & it was designed to
avoid a single large central database
● It is the only system of its kind that will allow you to browse & use the internet , Its use
is necessary for most companies & the people across the world
● DNS enables you to specify the technical functionality of the database service , It can
define the DNS protocol , the detailed specification of the data structures & the data
communication exchanges used in the DNS
OR
Answer
Electronic Mail (e-mail) is one of most widely used services on the Internet. This service
allows an Internet user to send a message in formatted manner (mail) to the other Internet
user in any part of the world. Messages in mail not only contain text, but it also contains
images, audio and videos data.
The person who is sending mail is called the sender and the person who receives mail is
called recipient. It is just like postal mail service.
Components of Email:
● User Agents
● Mail Servers
● Protocols
● Composition
The composition refers to the process that creates messages and answers. For
composition any kind of text editor can be used.
● Transfer
Transfer means sending a procedure of mail i.e. from the sender to recipient.
● Reporting
Reporting refers to confirmation for delivery of mail. It helps users to check whether
their mail is delivered, lost or rejected.
● Displaying
It refers to present mail in a form that is understood by the user.
● Disposition
This step concerns what the recipient will do after receiving mail i.e save mail, delete
before reading or delete after reading.
Answer:
Answer
An email gateway is a type of email server that protects an organization or user's internal
email servers. This server acts as a gateway through which every incoming and outgoing
email passes through. A Secure Email Gateway (SEG) is a device or software used for email
monitoring that is being sent and received.
A Secure Email Gateway (SEG) is a solution that protects the organization’s internal email
servers by analyzing and inspecting every incoming or outgoing email before it finds its way
into a user’s email Inbox.
A secure web gateway is a network security device that protects users who are accessing the
Internet against web-based threats. It does so by preventing malicious traffic that may result
in malware infection or network intrusion.
The goal of a Secure Email Gateway is to detect any unwanted and malicious emails and
stop them before they cause damage to the organization.
Answer
The network virtual terminal is an interface that defines how data and commands are sent
across the network.
In today's world, systems are heterogeneous. For example, the operating system accepts a
special combination of characters such as end-of-file token running a DOS operating system
ctrl+z while the token running a UNIX operating system is ctrl+d.
TELNET solves this issue by defining a universal interface known as network virtual interface.
The TELNET client translates the characters that come from the local terminal into NVT form
and then delivers them to the network. The Telnet server then translates the data from NVT
form into a form which can be understandable by a remote computer.
Answer
1. Rlogin:A client/server model can create a mechanism that allows a user to establish a
session on the remote machine and then run its applications. This application is known
as remote login. This can be done by a client/server application program for the desired
service.
● TELNET
● SSH
TELNET Protocol
Properties of TELNET:
● Client programs are built to use the standard client/server interfaces without knowing
the details of server programs.
● A client and a server can negotiate data format options
● Once a connection is established through TELNET, both ends of the connection are
treated symmetrically
1. Virtual Private Networking
A virtual private network (VPN) is a technology that creates a safe and encrypted connection
over a less secure network, such as the internet. Virtual Private network is a way to extend a
private network using a public network such as the internet. The name only suggests that it is
a Virtual private network i.e. a user can be the part of a local network sitting at a remote
location. It makes use of tunneling protocols to establish a secure connection.
1. Firewall
A firewall can be defined as a special type of network security device or a software program
that monitors and filters incoming and outgoing network traffic based on a defined set of
security rules. It acts as a barrier between internal private networks and external sources
(such as the public Internet).
The primary purpose of a firewall is to allow non-threatening traffic and prevent malicious or
unwanted data traffic for protecting the computer from viruses and attacks. A firewall is a
cybersecurity tool that filters network traffic and helps users block malicious software from
accessing the Internet in infected computers.
Answer:
● A user is logged in to the local system, and invokes a TELNET program (the TELNET
client) by typing telnet xxx.xxx.xxx where xxx.xxx.xxx is either a host name or an IP
address. The TELNET client is started on the local machine. That client establishes a
TCP connection with the TELNET server on the destination system. Once the
connection has been established, the client program accepts keystrokes from the user
and relays them, generally one character at a time, to the TELNET server.
● In general, a TELNET server is implemented as a master server with some number of
slave servers. The master server listens for service requests from clients. When it
hears one, it spawns a slave server to handle that specific request, while the master
goes back to listening for more requests.
● When you contact the host, the distant computer and your computer negotiate how to
communicate with each other When client and server communicate they use Telnet
protocol
● You can start the service manually every time you want to connect to a host, Or you
can configure the service so that it starts every time your computer starts. Telnet clients
cannot connect to a host unless a Telnet server program (or service) is running and
listening for connection requests.
● When running a Telnet client, it makes a connection request to the host (Telnet server).
If a Telnet server responds to the request, the Telnet client and server negotiate the
details of the connection, such as flow control settings, window size, and terminal type.
After the connection details are successfully negotiated, and logon credentials are
validated, the Telnet server program creates a Telnet command console session.
1. POP3
2. IMAP
3. SMTP
Answer
● The POP3 is a simple protocol and has very limited functionalities. In the case of the
POP3 protocol, the POP3 client is installed on the recipient system while the POP3
server is installed on the recipient's mail server.
● Suppose the sender wants to send the mail to the receiver. First mail is transmitted to
the sender's mail server. Then, the mail is transmitted from the sender's mail server to
the receiver's mail server over the internet. On receiving the mail at the receiver's mail
server, the mail is then sent to the user.
● The whole process is done with the help of Email protocols. The transmission of mail
from the sender to the sender's mail server and then to the receiver's mail server is
done with the help of the SMTP protocol. At the receiver's mail server, the POP or
IMAP protocol takes the data and transmits to the actual user.
● Since SMTP is a push protocol it pushes the message from the client to the server.
SMTP pushes the message from the client to the recipient's mail server. The third stage
of email communication requires a pull protocol, and POP is a pull protocol. When the
mail is transmitted from the recipient mail server to the client which means that the
client is pulling the mail from the server.
IMAP:
● The Internet Message Access Protocol (IMAP) is a mail protocol used for accessing
email on a remote web server from a local client. IMAP and POP3 are the two most
commonly used Internet mail protocols for retrieving emails. Both protocols are
supported by all modern email clients and web servers.
● While the POP3 protocol assumes that your email is being accessed only from one
application, IMAP allows simultaneous access by multiple clients. This is why IMAP is
more suitable for you if you’re going to access your email from different locations or if
your messages are managed by multiple users.
● By default, the IMAP protocol works on two ports:
○ Port 143 – this is the default IMAP unencrypted port;
○ Port 993 – this is the port you need to use if you want to connect using IMAP
securely.
SMTP:
SMTP mainly stands for Simple Mail Transfer Protocol. Basically, the actual transfer of mail is
done through the message transfer agents(MTA). Thus in order to send the mail, the system
must have the client MTA and in order to receive the mail, the system must have a server
MTA.
● In order to define the MTA client and server on the Internet, there is a formal way and it
is known as Simple Mail Transfer Protocol(SMTP).
● SMTP also makes the use of TCP/IP for sending and receiving e-mail.
● SMTP is based on the client/server model.
● The original standard port for SMTP is Port 25
Ques 15 Explain the SMTP can handle transfer of videos and images? Also explain the
advantages of IMAP4 over POP3 mail access protocols.
Answer:
- You can access your emails from any endpoint device, since all email messages are stored
on the server.
- With IMAP, multiple users can connect to a single mailbox, which is something you cannot
do with POP3. IMAPS provides better search capabilities when looking for emails.
- Another advantage of IMAP is that an email does not need to be deleted multiple times,
which can be a problem in POP3. In POP3, if an email message has been downloaded and
you have left a copy on the server, multiple copies of the same email exist, which makes
housekeeping a more difficult task.
- Because only the headings are downloaded initially, users can quickly select which emails
they want to download in full, and delete the unwanted emails. This provides ease and faster
access, especially for mobile users with limited bandwidth.
OR
Answer
● 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.
● It manages devices on IP networks.Devices that typically support SNMP include
routers,switches,servers,workstations,printers,modem racks and more.It is used mostly
in network management.
● Application program that allows manager to retrieve value of an object defined in agent,
a manager to store value in an object defined in agent,an agent to send alarm
information called trap event.
● 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.
Components of SNMP:
1. SNMP Manager –
It is a centralised system used to monitor network.It is also known as Network
Management Station (NMS)
2. SNMP agent –
It is a software management software module installed on a managed device. Managed
devices can be network devices like PC, router, switches, servers etc.
3. Management Information Base –
MIB consists of information of resources that are to be managed. These information is
organised hierarchically. It consists of objects instances which are essentially variables.
Ques 17 What is the difference between an active web document and dynamic web
page? Also explain the role of CGL.
Answer
An active web page is a page where the browser Dynamic is what's being executed on the
performs the logic instead of the server. So for server and then the result is being sent back
example when you've got a page where you're to the client (browser). So for example when
showing share prices, then you want it to update e.g. using PHP, your browser isn't able to execute
every 5 seconds. A solution would be to use AJAX PHP, so the server executes the PHP file and
with JavaScript. In contrast to PHP, your browser is performs all logic in your code. The result will
able to execute JavaScript, so it is happening without be an HTML file, which is then sent back to
reloading the page. So with an active page, the client. The important thing to understand
everything is happening inside your browser without is that when the result is served to the client,
the need to reload the page every time you want new the information in it won't change
information.
An active web document consists of a computer A dynamic web document does not exist in a
program that the server sends to the browser and that predefined form. When a request arrives the
the browser must run locally. When it runs, the active web server runs an application program that
document program can interact with the user and creates the document. The server returns the
change the display continuously. output of the program as a response to the
browser that requested the document.
Because a fresh document is created for
each request, the contents of a dynamic
document can vary from one request to
another.
● A widely used technology for building dynamic Web documents is known as the
Common Gateway Interface(CGI), originally developed by the National Center for
Supercomputer Applications (NCSA).
● The CGI standard specifies how a server interacts with an application program that
implements a dynamic document. The application is called a CGI program .
● CGI does not specify a particular programming language. A programmer can choose
an appropriate language for each document(C,C++, Perl, shell di Unix..).
Answer
The Hypertext Transfer Protocol is an application protocol for distributed, collaborative,
hypermedia information systems that allows users to communicate data on the World Wide
Web.
As a request-response protocol, HTTP gives users a way to interact with web resources such
as HTML files by transmitting hypertext messages between clients and servers. HTTP clients
generally use Transmission Control Protocol (TCP) connections to communicate with servers.
Request Methods :
Ques 19 Explain the principle of HTTP operation. Why is it called stateless protocol?
Answer:
The HTTP is meant for request/response depending on a client-server architecture where the
user requests information through a web browser to the web server, which then responds to
the requested data.
Web Client: The client of this client-server architecture asks for a request to a specific server
through the HTTP (TCP/IP connection) as a request method in the form of a URL. It also
contains a MIME-like message that contains request modifier and client information.
Web Server: This accepts the request and process with a response by a status line, together
with the version of the message's protocol as well as the success or error code, followed by a
MIME-like message having server information, some metadata, and possible the entity-body
content holding the requested information.
HTTP is a stateless protocol. This means a HTTP server needs not keep track of any state
information. So,
● At any time, client can send any valid command. The server will not relate this
command to any previous or future commands. Each command is independent of any
other commands, past or future. Compare this to a stateful protocol like POP3: after
you enter a USER command you must enter a PASS command.
● A HTTP server wil not remember whether a client has visited it before, or how many
time.
Answer:
SMTP HTTP
Multiple objects sent in multipart message Single object encapsulated in its own response
message
Multiple objects message sent in a multipart Each object is encapsulated in its own response
message message
Transfers mails via Mail Servers Transfers files between Web Server and Web
Client
Answer
Characteristics:
Answer:
The Internet is called a network as it creates a network by connecting computers and servers
across the world using routers, switches and telephone lines, and other communication
devices and channels. So, it can be considered a global network of physical cables such as
copper telephone wires, fiber optic cables, tv cables, etc. Furthermore, even wireless
connections like 3G, 4G, or Wi-Fi make use of these cables to access the Internet.
Uses of Internet:
1. Electronic mail(email)
2. FTP File Transfer
3. Search Engines
4. E-Commerce
5. Online Booking
6. Cashless Transaction
7. Education
8. Collaboration
9. Social Networking
Applications of Internet:
Ques 23 Write a note on public network. Discuss any one of its services.
Answer
A public network is a type of network wherein anyone, namely the general public, has access
and through it can connect to other networks or the Internet.
There is no technical difference between a private and public network in terms of hardware
and infrastructure, except for the security, addressing and authentication systems in place.
A communications network that resides outside the organization's firewall. The term typically
refers to the Internet; however, there are military and financial networks that are public with
regard to the firewall but not part of the global Internet. Contrast with private networks.
Because any user can connect to a public network, its level of security needs to be
heightened and various anti-threat and malicious act precautions must be put in place.
Because anyone is able to access the network, malicious users may try to infiltrate the
systems of unsuspecting users. Many company secrets have been stolen from executives
using their laptops in coffee shops with public Wi-Fi.
Answer
Answer:
Aim:
Features:
● High Performance
● Cell Oriented Switching
● Multiplexing Technology to carry different types of traffic
● Utilizes Fixed-Length Packet
Services of ATM: