CN Internal Karan
CN Internal Karan
Unit -1
1. Explain the differences between the Workgroup Model and Domain Model in computer
networking.
Ans :-
Security & No centralized control; each device must Centralized security policies and
Administration be managed separately administration
Users must log in separately on each Users can log in from any device
Login Access
device within the domain
Ans :-
Network topologies are the physical and logical arrangements of devices in a network. Here are the
main types of network topologies, along with brief descriptions and diagrams:
1. Point-to-Point Topology
• Description: This is the simplest topology, connecting two nodes directly through a dedicated
link.
• Diagram:
2. Bus Topology
• Description: All devices are connected to a single cable (bus). Data is transmitted in both
directions until it reaches the intended recipient.
Computer Networks
• Diagram:
3. Ring Topology
• Description: Devices are connected in a circular configuration. Data travels in one direction
until it reaches its destination.
• Diagram:
• Use Cases: Applications requiring high data integrity, such as token-based networks.
4. Star Topology
• Description: All devices connect to a central hub or switch. This topology is easy to install
and maintain.
• Diagram:
Hub/switch
/ \
text
Node A Node B
text
| |
Node C Node D
```
5. Tree Topology
• Diagram:
Computer Networks
Root Node
/ \
Node A Node B
/\/
Node C Node D Node E Node F
```
6. Mesh Topology
• Description: Each device is connected to every other device, providing multiple paths for
data transmission.
• Diagram:
| | |
| | |
• Use Cases: High availability environments like air traffic control systems.
7. Hybrid Topology
• Description: Combines multiple topologies to leverage their strengths and improve flexibility
and scalability.
• Diagram:
3. What are the different types of servers used in a computer network? Explain any two in
detail.
Ans :-
1. File Servers:
• Function: Store and manage files, enabling users to access and share them across the
network.
• Details:
o They provide centralized storage, making it easier to back up and manage data.
2. Web Servers:
• Function: Host websites and web applications, responding to HTTP requests from clients
(web browsers).
• Details:
o They deliver web pages, images, and other content to users over the internet or
intranet.
o Software like Apache and Nginx are commonly used as web server platforms.
o They handle tasks like processing requests, serving dynamic content, and managing
security.
3. Database Servers:
• Function: Store and manage databases, providing access to data for applications and users.
• Details:
4. Mail Servers:
• Details:
o They use protocols like SMTP (Simple Mail Transfer Protocol) for sending and
POP3/IMAP (Post Office Protocol 3/Internet Message Access Protocol) for receiving
emails.
5. Print Servers:
• Details:
o They allow multiple users to share printers, reducing the need for individual printers
for each computer.
6. Application Servers:
• Details:
o They handle complex tasks like transaction processing and data management.
• Details:
8. Proxy Servers:
• Details:
o They can provide security by filtering traffic and hiding client IP addresses.
• Details:
Computer Networks
o They ensure that IP addresses are assigned correctly and avoid conflicts.
• Details:
Ans :-
A VLAN is a logical grouping of network devices that appear to be on the same physical LAN,
regardless of their actual physical location. In simpler terms, a VLAN allows you to segment a physical
network into multiple logical networks. This segmentation is achieved by configuring switches to
treat certain ports as if they were on separate, independent LANs.
• Increased Security: VLANs isolate network traffic, preventing unauthorized access between
different groups of users or devices.
• Simplified Network Management: VLANs make it easier to manage and organize network
resources, especially in large and complex networks.
• Flexibility: VLANs allow you to create logical network segments without physically moving
devices or rewiring the network.
1. Creating VLANs:
o You begin by creating VLANs with unique IDs (VLAN IDs). VLAN IDs range from 1 to
4094. VLAN 1 is usually the default VLAN.
o Using the switch's command-line interface (CLI) or graphical user interface (GUI), you
create new VLANs and assign them names (e.g., VLAN 10 for "Sales," VLAN 20 for
"Marketing").
Computer Networks
▪ enable
▪ configure terminal
▪ vlan 10
▪ name Sales
▪ vlan 20
▪ name Marketing
▪ exit
o Next, you assign switch ports to specific VLANs. This determines which devices will
be part of each logical network.
▪ switchport trunk allowed vlan 10,20 (allows VLAN 10 and 20 traffic on the
trunk)
▪ exit
o Trunk ports carry traffic for multiple VLANs, allowing data to flow between switches
or routers that connect different VLANs.
o A router or layer 3 switch will provide the routing functionality to allow traffic to
move between the logically seperated networks.
5. Verification:
o After configuring VLANs, you can use commands to verify the configuration, such as
show vlan brief or show interfaces switchport.
Important Considerations:
• VLAN configuration can vary slightly depending on the switch vendor and model.
• Proper planning and documentation are essential for successful VLAN implementation.
• Security best practices should be followed when configuring VLANs to ensure network
security.
5. Compare wired and wireless networks. List their advantages and disadvantages.
Ans :-
Wired Networks
• Description:
o Wired networks use physical cables (like Ethernet cables) to connect devices.
• Advantages:
o Reliability: Wired connections are typically more stable and less prone to
interference.
o Security: Wired networks are generally considered more secure because physical
access is required.
o Lower Latency: Wired connections usually have lower latency, which is important for
applications like online gaming and video conferencing.
• Disadvantages:
o Limited Mobility: Devices are restricted to the location of the cable connection.
Wireless Networks
• Description:
• Advantages:
o Mobility: Users can connect from anywhere within the network's range.
o Ease of Installation: Wireless networks are generally easier and less expensive to set
up.
• Disadvantages:
o Speed: Wireless speeds can be slower and less consistent than wired speeds.
o Reliability: Wireless signals can be affected by interference from other devices and
obstacles.
Key Differences :
• Connection:
• Speed:
o Wired: Faster.
o Wireless: Slower.
• Reliability:
• Security:
• Mobility:
o Wired: Limited.
o Wireless: High.
6. Explain the OSI Model with a diagram, mentioning the function of each layer.
Ans :-
The OSI (Open Systems Interconnection) model is a conceptual framework used to understand how
data is transmitted over a network. It consists of seven layers, each with specific functions that
enable communication between devices.
Computer Networks
• Function: Establishes the physical connection between devices, transmitting raw bits
over a medium such as cables or wireless signals.
• Function: Ensures error-free transfer of data frames between two devices on the
same network. It manages access to the network and performs error checking.
• Function: Routes data between different networks, using logical addresses (IP
addresses) to determine the best path for data packets.
• Function: Provides reliable data transfer between devices, ensuring that data is
delivered in the correct order and without duplication. It manages flow control and
error recovery.
• Function: Converts data into a format that can be understood by the receiving
device, handling tasks like data compression, encryption, and character translation.
• Examples: HTTP (Hypertext Transfer Protocol), FTP (File Transfer Protocol), SMTP
(Simple Mail Transfer Protocol).
Computer Networks
Each layer communicates with its peer layer on other devices through a process called
"encapsulation," where data from a higher layer is wrapped in headers and trailers from lower layers
before being transmitted over the network.
Ans :-
The TCP/IP model is a conceptual framework used to understand and implement network protocols.
It consists of four layers, each responsible for specific functions in the communication process. Below
is a description of each layer along with a diagram.
1. Application Layer:
o Provides network services directly to user applications (e.g., web browsers, email
clients).
2. Transport Layer:
3. Internet Layer:
Computer Networks
o Manages the physical transmission of data over network hardware (e.g., Ethernet,
Wi-Fi).
8. What are the IEEE standards related to networking? List at least five with their functions.
Ans :-
Computer Networks
9. Define Firewall Authentication and describe different methods used for authentication.
Ans :-
A firewall is a security device that controls incoming and outgoing network traffic based on security
rules. Firewall authentication ensures that only authorized users can access restricted resources by
requiring identity verification before granting access.
o Example: Logging into a corporate network firewall with a username and password.
3. Certificate-Based Authentication
4. Biometric Authentication
7. Kerberos Authentication:
o Uses tickets to verify identities without sending passwords over the
network.
o Offers secure authentication for users accessing network resources.
10. Explain TCP/IP Reference Model and compare it with the OSI Model.
Ans :-
1. Application Layer:
2. Transport Layer:
o This layer handles logical addressing (IP addresses) and routing of data packets
across networks.
o It determines the best path for data to travel from source to destination.
o This layer deals with the physical transmission of data over the network medium.
Computer Networks
o It encompasses the functions of the OSI model's Data Link and Physical layers.
o It handles physical addressing (MAC addresses) and access to the network medium.
Key Differences:
• The TCP/IP model is simpler, with fewer layers, making it more practical for real-world
implementation.
• The OSI model is more comprehensive and provides a detailed framework for understanding
network communication.
• The TCP/IP model combines several OSI layers into single layers (Application and Network
Access).
• The TCP/IP model was created after the internet was created and is built around the internet
protocols. The OSI model was created to define how any network communications should
function, and was created before the modern internet.
11. List and explain any three network connecting devices with their functions.
Computer Networks
Ans :-
• Function:
o It translates data between the computer's internal format and the network's format.
o Provides a physical connection to the network medium (e.g., Ethernet cable, Wi-Fi
antenna).
• Explanation: Every device that connects to a network needs a NIC. It provides the hardware
interface that allows the device to send and receive data.
2. Hub:
• Function:
o A simple device that connects multiple devices in a local area network (LAN).
• Explanation: Hubs operate at the physical layer (Layer 1) of the OSI model. They are
considered "dumb" devices because they simply broadcast all data, leading to network
congestion and security risks. They are mostly obsolete now.
3. Switch:
• Function:
o Forwards data packets only to the intended destination device, based on MAC
addresses.
• Explanation: Switches are more intelligent than hubs. They learn the MAC addresses of
connected devices and create a table to map them to specific ports. This allows them to
forward data efficiently and reduce network congestion.
4. Router:
• Function:
• Explanation: Routers are essential for connecting networks and enabling communication
between them. They use routing tables to determine the optimal path for data packets.
Computer Networks
5. Modem (Modulator-Demodulator):
• Function:
o Converts digital signals from a computer or network device into analog signals for
transmission over analog media (e.g., telephone lines, cable TV lines).
o Converts analog signals back into digital signals at the receiving end.
• Explanation: Modems are used to connect devices to the internet or other networks over
analog connections. They are less common now with the proliferation of digital connections.
• Function:
• Explanation: WAPs are used to create wireless LANs (WLANs). They provide a bridge
between wired and wireless networks.
7. Firewall:
• Function:
o A network security device that monitors and controls incoming and outgoing
network traffic.
• Explanation: Firewalls protect networks from unauthorized access and malicious traffic. They
play a crucial role in network security.
8. Bridge:
• Function:
o It reduces network traffic by only forwarding traffic that needs to cross the network
segment.
Computer Networks
Unit - 2
Ans :-
SIP (Session Initiation Protocol) is a signaling protocol used for initiating, maintaining, and
terminating real-time communication sessions involving voice, video, and messaging applications
over Internet Protocol (IP) networks. It's a key component of Voice over IP (VoIP) systems and other
multimedia communication services.
• Session Termination: SIP ends communication sessions when they are no longer needed.
• User Capabilities: It negotiates the capabilities of the participants (e.g., supported codecs).
o SIP is widely used in VoIP systems to initiate and manage phone calls over the
internet.
o When you make a VoIP call, SIP messages are exchanged between your device and
the VoIP server to establish the connection.
2. Video Conferencing:
o It handles the negotiation of video and audio codecs, as well as the exchange of
video and audio streams.
o Applications like Zoom, and Microsoft Teams, use SIP in their background operations.
o While XMPP is also very common in IM, SIP can also be used.
4. Multimedia Collaboration:
Computer Networks
SIP's Operation:
• It uses a text-based protocol, similar to HTTP, making it relatively easy to implement and
debug.
• SIP messages are exchanged between SIP entities, such as user agents (phones, computers)
and SIP servers (proxy servers, registrar servers).
• SIP uses a request-response model, where a client sends a request and a server sends a
response.
2. Explain the working of FTP (File Transfer Protocol) and its modes of operation.
Ans :-
FTP (File Transfer Protocol) is a standard network protocol used for the transfer of computer files
between a client and a server on a computer network. It is built on a client-server model architecture
and uses separate control and data connections between the client and the server.
Working of FTP:
1. Connection Establishment:
o The client initiates a control connection to the server on port 21. This connection is
used for sending commands and receiving responses.
o The client authenticates with the server using a username and password.
o The client sends commands to the server through the control connection (e.g., LIST
to list files, RETR to retrieve a file, STOR to store a file).
3. Data Transfer:
o The data connection can be established in two modes: active and passive.
Computer Networks
4. Connection Termination:
o The client can continue to send commands through the control connection or close it
to end the session.
Modes of Operation:
FTP has two modes of operation for establishing the data connection:
1. Active Mode:
o In active mode, the client opens a random port (N > 1024) and sends this port
number to the server in a PORT command.
o The server then initiates the data connection from port 20 (FTP-DATA) to the client's
specified port (N).
o This mode can cause problems with firewalls, as the server initiates the connection
to the client, which might be blocked.
2. Passive Mode:
o The server opens a random port (P > 1024) and sends this port number back to the
client.
o The client then initiates the data connection from its random port (M > 1024) to the
server's specified port (P).
o This mode is generally more firewall-friendly, as the client initiates both the control
and data connections.
Ans :-
SSL (Secure Sockets Layer) and TLS (Transport Layer Security) are cryptographic protocols designed to
provide communication security over a computer network. They are used to establish an encrypted
link between a server and a client (e.g., a web server and a web browser). While SSL is the
predecessor, TLS is its more secure and updated version, and the terms are often used
interchangeably.
• Encryption: SSL/TLS encrypts data transmitted between the client and server, making it
unreadable to anyone who intercepts it.
• Authentication: It verifies the identity of the server (and optionally the client) to ensure that
the communication is with the intended party.
• Integrity: It ensures that the data has not been tampered with during transmission.
Computer Networks
1. Confidentiality:
2. Authentication:
o Clients can be sure they are communicating with the legitimate server.
3. Data Integrity:
o SSL/TLS uses message authentication codes (MACs) to ensure that data has not been
altered during transmission.
▪ Eavesdropping
▪ Man-in-the-middle attacks
▪ Data tampering
▪ Session hijacking
1. Handshake:
o The client and server negotiate the encryption algorithms and keys to be used.
o The client verifies the certificate with a trusted Certificate Authority (CA).
2. Encryption:
o Once the handshake is complete, the client and server use the agreed-upon
encryption algorithms and keys to encrypt and decrypt data.
3. Data Transfer:
4. Connection Closure:
Computer Networks
• Web Browsing (HTTPS): Secures communication between web browsers and web servers.
Ans :-
In computer networking, a socket is one endpoint of a two-way communication link between two
programs running on a network. It's an abstraction that represents the interface through which a
process can send and receive data over a network. Essentially, a socket is a combination of an IP
address and a port number.
• Port Number: Identifies the specific application or process running on the host.
TCP (Transmission Control Protocol) is a connection-oriented protocol that provides reliable, ordered,
and error-checked delivery of data. Establishing a TCP connection involves a three-way handshake,
and sockets play a crucial role in this process.
o The server application creates a socket and binds it to a specific IP address and port
number.
o This socket is then put into a "listening" state, waiting for incoming connection
requests.
Computer Networks
o The client application creates a socket and initiates a connection request to the
server's IP address and port number.
3. Three-Way Handshake:
o SYN (Synchronize):
o SYN-ACK (Synchronize-Acknowledge):
▪ The server creates a new socket to handle the connection with the client.
▪ The server sends a SYN-ACK packet back to the client, acknowledging the
client's SYN and sending its own SYN with its initial sequence number.
o ACK (Acknowledge):
▪ The client sends an ACK packet back to the server, acknowledging the
server's SYN.
▪ At this point, the TCP connection is established between the client's socket
and the server's new socket.
4. Data Transfer:
o Once the connection is established, the client and server can use their respective
sockets to send and receive data.
5. Connection Termination:
o When either the client or server is done with the connection, the sockets are used to
preform the four way handshake that closes the TCP connection.
Computer Networks
Ans :-
6. Describe the SMTP (Simple Mail Transfer Protocol) and its role in email
communication.
Ans :-
SMTP (Simple Mail Transfer Protocol) is an application-layer protocol used for sending and receiving
email messages over the internet. It is a connection-oriented protocol that relies on TCP
(Transmission Control Protocol) to ensure reliable data transfer between email servers and clients.
1. Email Delivery:
• Function: SMTP facilitates the delivery of emails from the sender's email client to the
recipient's email server. It does not handle email retrieval; that is typically done by
protocols like POP3 or IMAP.
2. Server-to-Server Communication:
Computer Networks
• Example: When sending an email from Gmail to Yahoo, SMTP is used by Gmail's
server to forward the email to Yahoo's server.
3. Standardization:
• Function: SMTP standardizes the process of email transmission, ensuring that emails
can be sent and received across different networks and systems.
• Function: SMTP uses a set of text-based commands (e.g., HELO, MAIL FROM, RCPT
TO, DATA) and responses (e.g., 250 OK) to manage the email transfer process.
• Example: The HELO command is used by the client to initiate a connection with the
server.
5. Limitations:
• Function: SMTP originally supports only plain text and does not handle attachments
directly. MIME (Multipurpose Internet Mail Extensions) is used to extend SMTP
capabilities for sending attachments and formatted messages.
Ans :-
SNMP (Simple Network Management Protocol) is an application-layer protocol used for monitoring
and managing network devices over IP networks. It allows network administrators to manage and
monitor network elements such as routers, switches, printers, and servers remotely.
Components of SNMP
SNMP consists of several key components that work together to facilitate network management:
• Function: Acts as the central system for monitoring and managing network devices.
It queries agents for information, sets variables, and receives alerts.
2. Managed Devices:
Computer Networks
• Function: These are network devices that have an SNMP agent installed, allowing
them to be monitored and managed. Examples include routers, switches, and
printers.
• Example: A network router with an SNMP agent that reports its status and
performance metrics.
3. SNMP Agent:
• Function: Software that runs on managed devices, collecting and storing information
about the device's status and performance. Agents respond to queries from the
SNMP manager and can send alerts.
• Example: An agent on a printer that reports paper jam errors to the NMS.
• Example: A MIB file on a router that contains OIDs for monitoring CPU usage and
memory allocation.
8. Explain the TCP connection establishment and termination process using a three-way
handshake diagram.
Computer Networks
Ans :- The three-way handshake is the process used to establish a reliable TCP connection
between a client and a server.
SYN (Synchronize):
• The client initiates the connection by sending a SYN packet to the server.
• The SYN packet signals the server that the client wants to establish a connection.
SYN-ACK (Synchronize-Acknowledge):
• This packet includes the server's initial sequence number (Seq=Y) and an acknowledgment
number (Ack=X+1), which indicates that the server has received the client's SYN.
• The SYN-ACK packet also signals the client that the server is ready to establish a connection.
ACK (Acknowledge):
• This packet includes an acknowledgment number (Ack=Y+1), which indicates that the client
has received the server's SYN-ACK.
• At this point, the TCP connection is established, and data transfer can begin.
9. What is RTP (Real-time Transport Protocol)? How is it used for multimedia streaming?
Computer Networks
Ans :-
RTP (Real-time Transport Protocol) is a network protocol designed for delivering audio and video
over IP networks in real-time. It is widely used for streaming multimedia applications, such as video
conferencing, live broadcasting, and VoIP (Voice over IP).
1. Real-Time Delivery:
o RTP is optimized for real-time communication, ensuring low latency for time-
sensitive data like audio and video.
2. Payload Identification:
o RTP headers include information about the type of data being transmitted (e.g.,
audio, video) and its encoding format (e.g., H.264, MP3).
3. Sequence Numbers:
o RTP uses sequence numbers to detect lost packets and ensure data is delivered in
the correct order.
4. Timestamps:
o Timestamps in RTP headers help synchronize audio and video streams, ensuring
smooth playback.
o RTP does not provide error correction or retransmission of lost packets. Instead, it
relies on lower-layer protocols (e.g., UDP) for fast delivery.
1. Packetization:
o Audio and video data are divided into small packets, each with an RTP header.
o The RTP header contains information like sequence numbers, timestamps, and
payload type.
2. Transmission:
o RTP packets are transmitted over the network using UDP (User Datagram Protocol)
for low latency and high speed.
o UDP is preferred over TCP because it does not retransmit lost packets, which is
critical for real-time applications.
3. Synchronization:
o RTP uses timestamps to synchronize audio and video streams. This ensures that the
audio matches the video during playback.
Computer Networks
o It provides feedback on packet loss, jitter, and latency, helping applications adjust to
network conditions.
5. Playback:
o At the receiver's end, RTP packets are reassembled and decoded to produce the
original audio and video streams.
• Video Conferencing: Applications like Zoom, Skype, and Microsoft Teams use RTP to transmit
real-time audio and video.
• Live Streaming: Platforms like YouTube Live and Twitch use RTP to broadcast live events.
• VoIP: Services like WhatsApp Calls and Google Voice use RTP for voice communication.
Simple Analogy:
Think of RTP as a "delivery truck" for multimedia data. It packages audio and video into small boxes
(packets), labels them with timestamps and sequence numbers (headers), and delivers them quickly
using UDP. The receiver unpacks the boxes and plays the content in the correct order.
• Header: Contains sequence numbers, timestamps, payload type, and synchronization source
(SSRC).
10. Explain the function of DCCP (Datagram Congestion Control Protocol) and how it differs
from TCP and UDP.
Ans :-
DCCP (Datagram Congestion Control Protocol) is a transport layer protocol designed for applications
that require low-latency, reliable delivery of data without the strict ordering guarantees of TCP. It
combines features of both TCP (congestion control) and UDP (connectionless, low overhead), making
it suitable for real-time applications like streaming and online gaming.
Computer Networks
Functions of DCCP:
1. Congestion Control:
o It supports multiple congestion control algorithms (e.g., TCP-like, TFRC) that can be
selected based on the application's needs.
o Unlike TCP, DCCP does not guarantee reliable delivery or packet ordering. However, it
ensures that data is delivered with minimal delay, making it ideal for real-time
applications.
3. Connection-Oriented:
o DCCP establishes a connection between two endpoints (like TCP) but does not
maintain strict ordering or retransmit lost packets (like UDP).
4. Feature Negotiation:
o DCCP allows endpoints to negotiate features like congestion control mechanisms and
optional reliability during the connection setup.
5. Partial Reliability:
1. Reliability:
o DCCP offers optional reliability, allowing applications to choose which packets need
to be reliable.
2. Congestion Control:
o DCCP provides congestion control but allows flexibility in choosing the algorithm.
3. Packet Ordering:
o DCCP does not enforce strict ordering, making it faster for real-time applications.
4. Use Cases:
o TCP is used for applications where reliability is critical (e.g., file transfer).
o UDP is used for applications where speed is more important than reliability (e.g.,
video streaming).
o DCCP is used for real-time applications that need low latency and some level of
reliability (e.g., online gaming, streaming).
Simple Analogy:
• TCP is like a registered mail service: it ensures your package arrives safely and in order.
• UDP is like a postcard: it’s fast, but there’s no guarantee it will arrive or in what order.
• DCCP is like a courier service: it’s faster than registered mail, and you can choose whether to
get a delivery confirmation.