Computer Networks
Computer Networks
1. Resource Sharing: Sharing files, printers, and internet connections between devices.
2. Communication: Enabling communication via emails, chat, and voice/video calls.
3. Data Access and Transfer: Facilitating the transfer of data between computers or
devices.
4. Centralized Management: In a network, data can be managed, controlled, and stored
centrally (e.g., on a server).
1. Bus Topology
Description: All devices (computers, printers, etc.) are connected to a single central
cable, known as the "bus." Signals are sent along this cable to all devices.
Advantages: Simple, easy to set up, requires less cable.
Disadvantages: If the central cable fails, the whole network goes down. Performance
decreases as more devices are added.
2. Star Topology
Description: All devices are connected to a central device, usually a hub or switch.
Each device communicates with others through the central device.
Advantages: Easy to set up and manage. If one device fails, the others are
unaffected.
Disadvantages: The central device is a single point of failure. If it fails, the entire
network goes down.
3. Ring Topology
Description: Devices are connected in a closed loop or circle. Each device has two
neighbors, and data travels in one direction around the ring.
Advantages: Data travels at a consistent speed, and it's easy to troubleshoot.
Disadvantages: If one device or connection fails, the entire network can be disrupted
(unless it's a dual ring network).
4. Mesh Topology
Description: Every device is directly connected to every other device. This means
there are multiple paths for data to travel.
Advantages: Highly reliable, as data can take multiple routes. If one path fails, data
can still reach its destination.
Disadvantages: Expensive and complex to set up because of the large number of
connections.
5. Hybrid Topology
Description: This is a combination of two or more topologies. For example, a network
may use a star topology for the main network and a bus topology for sub-networks.
Advantages: Flexible, can be designed for specific needs.
Disadvantages: More complex to set up and maintain.
6. Tree Topology
Description: A combination of star and bus topologies. Groups of star-configured
devices are connected to a central bus.
Advantages: Scalable, easy to expand.
Disadvantages: If the central bus fails, the whole network can be affected.
1. Application Layer
2. Transport Layer
3. Internet Layer
4. Network Access Layer
Diagram
+---------------------------+
| Application Layer | <-- (Layer 4)
| - User applications (e.g. |
| web browsers, email) |
+---------------------------+
|
+---------------------------+
| Transport Layer | <-- (Layer 3)
| - Protocols: TCP, UDP |
| - End-to-end communication|
+---------------------------+
|
+---------------------------+
| Internet Layer | <-- (Layer 2)
| - Protocol: IP |
| - Routing, addressing |
+---------------------------+
|
+---------------------------+
| Network Access Layer | <-- (Layer 1)
| - Physical & Data Link |
| - Hardware (NIC, cables) |
+---------------------------+
This is the topmost layer where users interact with network services. It provides
the interface and protocols used by applications to communicate over the network.
Functions:
Provides services like email (SMTP, POP3), web browsing (HTTP, HTTPS), file transfer
(FTP), and more.
Translates application data into a form that can be transmitted over the network.
Handles user input/output and formatting of data.
Protocols:
HTTP (HyperText Transfer Protocol)
FTP (File Transfer Protocol)
SMTP (Simple Mail Transfer Protocol)
POP3 (Post Office Protocol)
This layer ensures end-to-end communication and provides reliable data transfer. It
manages the flow of data between devices and ensures that data is delivered
correctly and in sequence.
Functions:
Breaks data into segments and controls the flow of data.
Provides error handling, retransmission of lost data, and data integrity.
Handles flow control (managing the rate of data transmission).
Protocols:
TCP (Transmission Control Protocol): Connection-oriented, reliable, ensures data is
correctly received.
UDP (User Datagram Protocol): Connectionless, faster but less reliable (used for real-
time applications like video streaming, VoIP).
The Internet layer is responsible for logical addressing, routing, and packet
forwarding across networks. It defines how devices are addressed and located on the
network, ensuring data can travel between different networks.
Functions:
Handles IP addressing, routing, and packet forwarding.
Determines the best path for data to travel across networks.
Responsible for fragmentation and reassembly of packets.
Protocols:
IP (Internet Protocol): Provides logical addressing (IP addresses) and routing of
packets.
ICMP (Internet Control Message Protocol): Used for network diagnostics (e.g., ping).
ARP (Address Resolution Protocol): Resolves IP addresses to MAC addresses.
4. Network Access Layer (Layer 1)
The Network Access layer is responsible for how data is physically transmitted over a
network. This includes hardware devices, media, and protocols that define how data
moves between devices within the same network or across different networks.
Functions:
Transmits data over the physical medium (e.g., Ethernet cables, Wi-Fi).
Handles MAC addressing (hardware addresses) and how devices on the same
network communicate.
Ensures the correct framing of data and error detection at the data link level.
Protocols:
Ethernet: Most common protocol used for wired LANs.
Wi-Fi: Protocol for wireless LANs.
PPP (Point-to-Point Protocol): Used for direct connections between two devices.
In simple terms: PCM takes continuous analog signals (like voice or music) and
converts them into a sequence of digital pulses (binary numbers) that can be
transmitted or stored by digital devices.
While PCM is a traditional method of digital signal processing, modern variants and
techniques are often used to improve the quality and efficiency of transmission or
storage. The key types of PCM and their modern variants include:
1. Efficiency:
Since packets are routed independently and can take different paths, the network
can dynamically adjust to congestion and failures. This leads to better utilization of
available network resources.
2. Scalability:
Packet-switched networks can easily handle large volumes of data and scale to
accommodate millions of devices, as each device can send and receive data packets
independently without establishing a dedicated connection.
3. Fault Tolerance:
Because packets can take multiple paths, the network is fault-tolerant. Even if one
route fails, packets can be rerouted via alternative paths.
4. Flexible and Robust:
Packet switching is suitable for a variety of applications, from small messages to large
data transfers. It is robust because if part of the network is congested or fails, other
paths can be used to continue transmitting data.
5. Connectionless:
Packet switching does not require a dedicated end-to-end connection. Each packet is
independently routed, making it ideal for applications that need to transmit data
intermittently (e.g., web browsing, email).
1. Overhead:
Since each packet contains header information (such as source, destination, and
sequence number), there is additional overhead compared to circuit-switched
communication, where the connection is maintained for the entire session.
2. Variable Latency:
Packets may take different paths and arrive at the destination out of order, which
can lead to variable delays. This can be problematic for real-time applications (e.g.,
voice or video calls) that require consistent timing.
3. Congestion:
If too many packets are sent through the same network path, congestion can occur,
causing delays or packet loss. Quality of Service (QoS) mechanisms are sometimes
used to manage congestion in such cases.
The Internet: The fundamental technology behind the Internet is packet switching.
Websites, emails, and streaming services all rely on packet-switched networks for
data transmission.
Voice over IP (VoIP): VoIP services (like Skype or Zoom) use packet switching for
transmitting voice and video data over the internet.
File Transfer: Protocols like FTP and HTTP use packet switching to break large files
into smaller packets for efficient transmission.
Connection
Type Connectionless (no dedicated path) Connection-oriented (dedicated path)
Efficiency Highly efficient, especially with bursty data Less efficient, fixed bandwidth usage
1. Token Bus
Token Bus is a network topology in which the devices are connected to a single bus
(central cable), and a token circulates along the bus. Only the device that holds the
token can send data, while others must wait for the token to be passed to them.
2. Token Ring
FDDI is a high-speed network standard that uses fiber optics to form a dual-ring
network topology. It is designed for local and wide-area networks, providing high-
speed data transmission, redundancy, and fault tolerance.
In any communication system, errors can occur during data transmission due to
noise, signal degradation, or interference. Error detection and correction techniques
are crucial to ensure data integrity and reliable communication, especially in
networks where data is transferred over long distances or through unreliable
channels.
Error Detection
Error detection refers to the process of identifying whether an error has occurred in
the transmitted data. The primary goal is to detect if the data sent by the sender has
been altered during transmission. Common error detection methods include parity
bits, checksums, and cyclic redundancy checks (CRC).
Error Correction
While error detection allows the receiver to identify errors, error correction goes a
step further by enabling the receiver to fix the errors without the need for
retransmission. There are two types of error correction techniques: Forward Error
Correction (FEC) and Automatic Repeat Request (ARQ).
In FEC, additional data is added to the transmission, allowing the receiver to correct
errors without needing to ask the sender to retransmit the data. This is particularly
useful in real-time communications or situations where retransmission is costly or
impractical (e.g., satellite communications, streaming).
Techniques:
1. Hamming Code: A well-known error-correcting code that can correct single-bit errors
and detect two-bit errors. It adds redundancy bits to the original data, enabling the
receiver to both detect and correct errors.
Example: In a 7-bit Hamming code, 4 bits are data, and 3 bits are redundancy. The
receiver checks the redundancy bits and can identify and correct errors in the 4 data
bits.
2. Reed-Solomon Codes: Used in applications such as CDs, DVDs, and QR codes, Reed-
Solomon codes can correct multiple errors within a block of data.
3. Turbo Codes and LDPC Codes: These are more advanced error-correction schemes
used in modern communication systems, including 4G and 5G cellular networks,
providing high efficiency in error correction.
Automatic Repeat Request (ARQ)
In ARQ, the receiver detects errors and requests the sender to retransmit the
affected data. ARQ protocols rely on error detection techniques (like checksums or
CRC) and acknowledgment messages to ensure data integrity.
Types of ARQ:
1. Stop-and-Wait ARQ: The sender sends one data packet at a time and waits for an
acknowledgment (ACK) before sending the next packet. If no acknowledgment is
received or if an error is detected, the sender retransmits the packet.
Disadvantages: It is inefficient because it requires waiting for an acknowledgment
after every packet.
2. Go-Back-N ARQ: The sender can send multiple packets without waiting for
acknowledgments but must retransmit all packets from the erroneous one if an error
is detected.
Disadvantages: Retransmitting multiple packets can cause inefficiency in the case of
errors.
3. Selective Repeat ARQ: The sender can send multiple packets and retransmit only the
erroneous packets (rather than all packets from the point of error). This is more
efficient than Go-Back-N ARQ.
Advantages: More efficient than Go-Back-N because only the problematic packets
are retransmitted.
Efficiency Relatively simple and fast More complex, but reduces retransmissions
Mitigation:
Mitigation:
DoS: A single device floods the target with traffic, exhausting resources and causing a
service outage.
DDoS: A large number of compromised devices (often a botnet) work together to
flood the target system, making it even harder to defend.
Mitigation:
Mitigation:
Mitigation:
Mitigation:
Example: An attacker using a brute force attack to guess a weak password and gain
access to an account.
Mitigation:
8. Insider Threats
An insider threat refers to a security threat that originates from within the
organization. This could be a disgruntled employee, a contractor, or even a trusted
partner who intentionally or unintentionally causes harm.
Mitigation:
9. Lack of Encryption
Encryption is essential for protecting sensitive data during transmission and storage.
Without proper encryption, data is vulnerable to interception, eavesdropping, and
tampering.
Example: Sending sensitive data over the internet without encryption exposes it to
potential hackers.
Mitigation:
Use strong encryption algorithms (e.g., AES, RSA) to secure data at rest and in transit.
Ensure that communication channels (e.g., web traffic) use SSL/TLS protocols.
Implement end-to-end encryption in messaging services and applications.
Mitigation:
Example: A hacker accessing a network and exfiltrating data over several days
without being detected.
Mitigation:
Implement Intrusion Detection Systems (IDS) and Intrusion Prevention Systems (IPS).
Set up network monitoring tools to track traffic, devices, and activities.
Enable comprehensive logging to capture system and network activities for later
analysis.
In a supply chain attack, attackers target the vendors or third-party service providers
that are connected to the organization’s network. These attacks can compromise the
organization by exploiting vulnerabilities in software or hardware provided by
external vendors.
Mitigation:
Q. Write notes on :—
(a) email
(b) remote login
(c) Access Control
(d) Network Security
(e) Cryptography
(f) Privacy
(a) Email
Email (Electronic Mail) is one of the most commonly used communication methods
over the Internet. It allows users to send, receive, and store messages electronically.
Email is a critical tool for personal, business, and educational communication.
Components of Email:
1. Email Client: Software or application used by the user to send and receive emails
(e.g., Outlook, Gmail, Thunderbird).
2. Email Server: A computer system that stores emails and delivers them to the
recipient’s client. Common types include:
SMTP (Simple Mail Transfer Protocol): Used for sending emails.
POP3 (Post Office Protocol): Used for retrieving emails from the server.
IMAP (Internet Message Access Protocol): Allows synchronization of emails across
multiple devices.
3. Email Address: A unique identifier for each user on the email network
(e.g., [email protected]).
4. Attachments: Files that can be attached to an email for sharing (e.g., documents,
images).
Email Security Issues:
Phishing: Fraudulent attempts to acquire sensitive information (e.g., login
credentials).
Spam: Unsolicited emails, often used for advertising or spreading malware.
Email Spoofing: Impersonating someone’s email address to deceive the recipient.
Security Measures:
Encryption: Secure email encryption (e.g., PGP, S/MIME) to protect the content.
Anti-Spam and Anti-Phishing Filters: To detect and block malicious emails.
Two-Factor Authentication (2FA): Adds an additional layer of security when accessing
email accounts.
(b) Remote Login
Remote Login allows a user to access a computer system or network from a distant
location over the internet or a private network. It enables remote administration and
usage of resources without being physically present.
Access Control refers to the process of managing and restricting access to network
resources, systems, or information. The goal is to ensure that only authorized users
or devices can access certain resources.
(e) Cryptography
(f) Privacy
Privacy refers to the right of individuals to control their personal information and to
keep it from being exposed, collected, or misused without their consent. In the
digital world, privacy concerns often relate to how personal data is collected, stored,
and used.
Types of Privacy:
1. Data Privacy:
Protecting personal data from unauthorized access, use, or disclosure.
Regulations like GDPR (General Data Protection Regulation) emphasize the right to
privacy and data protection.
2. Communication Privacy:
Ensuring that communications (e.g., emails, phone calls) are kept confidential and
not intercepted or monitored by unauthorized parties.
3. Online Privacy:
Protecting personal information (e.g., browsing habits, location data) when using
online services.
Techniques like anonymous browsing, use of VPNs, and privacy-focused search
engines help protect online privacy.
Privacy Risks:
Surveillance: Governments or third parties tracking personal data or online activity.
Data Breaches: Unauthorized access to databases storing personal information.
Privacy Protection Measures:
Encryption: Protects sensitive data from being accessed by unauthorized individuals.
Anonymous Browsing Tools: Tools like Tor or VPNs help protect online activity from
being tracked.
Consent: Obtaining explicit permission from users before collecting or processing
personal data.
ISDN aims to integrate both voice and data services into a single network, offering
faster and more efficient communication compared to earlier technologies. It uses
digital transmission to provide higher quality and greater reliability.
ISDN divides the communication process into two major parts: the B-Channel and
the D-Channel.