Chapter 6 - Introduction to Computer Networks
Comprehensive Questions & Answers for Class 9 Computer Science (Punjab Board)
Data Communication and its Components
Data communication:
Data communication refers to exchange of message between sending and receiving device through some communication medium. These messages are actually the information which can be presented in many forms like text, numbers, images, audio and video.
Components of Data Communication:
- Message
- Communication medium
- Sender
- Receiver
Role of Routers in Computer Network
Role of Router:
A router is a networking device that interconnects networks or allows devices to connect to it. It directs data packets between different networks. Think of it as a traffic director on the internet, making sure that data gets from one place to another efficiently.
Functions of Network Layer in OSI Model
Function of Network layer:
Network layer is responsible for data transfer between different networks. It determines the best path for data to travel from the source to the destination.
Example:
Imagine a GPS system finding the best route for you to travel from the school to home, or home to school.
Packet Switching vs Circuit Switching
| Packet Switching | Circuit Switching |
| Data is divided into small packets and sent separately over different routes. | A dedicated path is established b/w sender and receiver before communication start. |
| Packets may take different paths and are reassembled at the destination. | All data follows the same path ensuring a continuous connection. |
| More efficient and faster as it uses network resources dynamically. | Less efficient as the circuit remains busy even if no data is sent. |
| Used in the internet, emails and VoIP. | Used in traditional telephones calls, where a fixed line is maintained during the call. |
Purpose of DHCP
Purpose of DHCP:
DHCP automatically assigns IP addresses to devices on a network, simplifying network management.
Example:-
When a device connects to a Wi-Fi network, DHCP assigns it an IP address.
Role of Encapsulation in Security
Role of Encapsulation in Security:
Encapsulation keeps data safe in a network by wrapping it in protective layers. Each layer adds important details, like sender and receiver info, making it harder to hack. It also hides the real data, so only the right person can see it. This helps in secure and private communication.
TCP vs UDP
| TCP | UDP |
| Relibility | |
| TCP (Transmission Control Protocol) is reliable because it ensures that all data is received correctly. | UDP (User datagram protocol) is not reliable as it doesnot check for lost data. |
| Error Checking | |
| TCP checks for errors and resend lost data. | UDP does minimal error checking and doesnot resend lost data. |
| Speed Check | |
| TCP is slower due to reliability checks. | UDP is faster because it skips these checks. |
Importance of Encryption in Network Security
Importance of Encryption:
Encryption protects data by converting it into a secure format. Encryption keeps data safe by changing it into a secret code before sending it over a network. This makes sure that only the right person can read it. Even if hackers try to steal the data, they won't understand it. Encryption helps protect personal and important information from being misused.
Advantages of Star Topology
Advantages of Star Topology:
Here are the advantages of star topology.
- Easy to manage: If one computer has a problem, the rest of the network keeps working.
- Fast performance: Each device has a direct connection to the central hub, making data transfer quick.
- Easy to add device: New computers can be added without effecting the network.
- Strong Security: Data passes through a central hub, making it easier to monitor and control access.
Contribution of Firewalls to Network Security
Role of Firewall:
Firewall monitor and control incoming and outgoing network traffic. A firewall keeps a network safe by blocking harmful data and allowing only safe data to pass. It works like a security guard, stopping hackers and viruses from entering. This helps protects computers from cyber attack and keep information safe.
Objective of Computer Networks
Objective of computer networks:
The objective of computer networks is to enable resource sharing, data communication and collaboration.
- Resource sharing:
Computer networks allow devices to share resources such as printers and storage, reducing costs and improving efficiency.
Example:-
In an office network, multiple computer can share a single printer, reducing the need for multiple printers.
- Data communication:
Network facilitate data transfer, enabling communication through emails, instant messaging, and video conferencing.
Example:-
Employees in different locations can collaborate through video conferencing tools like Zoom or Microsoft Teams.
Simplex Communication System Numerical
To compute the transmission time, we use formula
Time = Message Size (in bits)
Data Rate (in bps)
Given:
Data rate = 500 bps
1 kilobit (kb) = 1000 bits
1 kilobytes (KB) = 8 x 1000 = 8000 bits
a) it is of 10 kilobitsTime
= (10,000 bits)/500 bps
= 20 seconds
b) it is of 10 kilobytesTime
= (10,000 x 8 bits)/500 bps
= 160 seconds.
Transmission Methods Using Packet and Circuit Switching
Transmission Methods:
Data can be transmitted across a computer network using packet switching or circuit switching.
Packet Switching:
Packet switching divides data into a small packets before sending them across a network. Each packet travels independently and may take different routes to reach the destination, where they are reassembled into the original message.
Process:
_-The data is broken into packets (small chunks)
_-Each packet contains a header (source, destination, sequence number, etc), and payload (actual data).
_-Packets are sent independently across the network.
_-Packets may take different paths based on network conditions.
-The destination device reorders packets and reconstructs the original message.
Circuit Switching:
Circuit switching establishes a dedicated communication path between the sender and receiver before data transmission begins. This path remains open for the entire session.
Process:
_-A connection (circuit) is established between sender and receiver.
_-Data flows continuously along the path.
_-After transmission, the connection is terminated.
Packet Switching is ideal for modern internet-based communication while Circuit Switching is still used in traditional voice calls but is less common for data transfers.
Role and Importance of Protocol
Protocol:-
Protocols are sets of rules that govern data communication. A protocol is a formal agreement arrangement between two computers send and receive information.
i) TCP/IP (Transmission Control Protocol/Internet Protocol):
Each layer of TCP/IP model has its own protocol(s). Every protocol is designed to perform some specific task.
ii) HTTP:
Hypertext Transfer Protocol is a protocol used by World Wide Web (WWW) to transfer webpages between a client and a webserver. A webserver is also called called an HTTP server.
iii) DNS (Domain Name System):-
DNS translates domain name to IP addresses, making it easier for users to access websites.
Example:
When you type www.example.com in a web browser DNS translates it to the corresponding IP address.
iv) DHCP(Dynamic Host Configuration Protocol):-
DHCP automatically assigns IP addresses to devices on a network, simplifying network management.
Network Security Methods
Introduction to Network Security:
Network security protects data from unauthorized access, cyber threats, and attacks. Below are three key security methods.
- Firewalls:-
A firewall acts as a security barrier between a private network and external threats. It monitors and controls incoming and outgoing traffic based on predefined security rules. Firewalls prevent unauthorized access but cannot detect threats hidden in encrypted traffic. - Encryption:- It protects data by converting it into a secure format, ensuring that only authorized users can decode it. It is essential for secure online communication, such as banking and messaging. However, encryption requires effective key management as losing the decryption key makes the data inaccessible.
- Antivirus Software:-
Antivirus software detects and removes malicious software. It provides real-time protection, but it needs frequent updates to stay effective against new threats. Despite its benefits, it cannot prevent attacks like phishing or social engineering.
Real World Applications of Networks
Introduction to Applications:
Computer network helps people to connect, share information and work efficiently. They are widely used in business, education, and healthcare to improve communication and services.
- Business:-
In Business, networks enables efficient communication, resource sharing, and data management.
Example:-
Companies use internet to share information and resources securely within the organization.
- Education:-
Educational institutions use networks to provide online learning platforms, virtual classrooms, and access to educational resources.
Example:-
Universities use Learning Management System (LMS) like Blackboard and Moodle to deliver course content and assessments.
- Healthcare:-
Healthcare networks facilitate the sharing of patient information, telemedicine, and access to medical database.
Example:-
Hospitals uses electronic health records (EHR) system to store and retrieve patient data effecti efficiently.
Types of Network Topologies
Star Topology:
- Structure: All devices connect to a central hub.
- Failure Impact: If the hub fails, the entire network goes down.
- Scalability: Easy to add/remove device without effecting the network.
- Cost: Moderate, requires a hub.
- Best use Cases: Office networks, LANs.
Ring Topology:
- Structure: Devices are connected in a closed loop.
- Failure Impact: If one device fails, the entire network can be disrupted.
- Scalability: Difficult to expand without breaking the ring.
- Performance: Moderate, as data passes through multiple devices before reaching the destination.
- Cost: Low, but expensive for large networks.
- Best use cases: Older Token Ring networks.
Bus Topology:
- Structure: A single backbone cable connects all devices.
- Failure Impact: If the main cable fails, the whole network stops working.
- Scalability: limited by cable length and signal degradation.
- Performance: Low, as all devices share bandwidth.
- Cost: Low, as minimal cabling is needed.
- Best use cases: Small networks with few devices.
Mesh topology:
- Structure: Each device is connected to everyother device.
- Failure Impact: Highly reliable, failure of one link doesnot effect the network.
- Scalability: Difficult to expand due to high cost and complexity.
- Performance: Very high, as multiple paths ensures smooth data flow.
- Cost: Very high, due to extensive cabling and configuration.
- Best use cases: High security environment like banking and military networks.
Shift Cipher with Shift Amount 4
Definition of Shift Cipher:
A shift cipher (Caesar cipher) shifts each letter in the alphabet by a fixed amount. In this case, the shift amount is 4.
a) Encrypt "SECURITY"
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
E F G H I J K L M N O P Q R S T U V W X Y Z A B C D
The word 'SECURITY' Encrypted in "WIGYVMX"
b) Decrypt "WMXYVMI"
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
E F G H I J K L M N O P Q R S T U V W X Y Z A B C D
The word "WMXYVMI" decrypt in "SITURIE"
IPv4 Address Calculation
Part a): Total IPv4 Addresses:
An IPv4 address is a 32-bit number meaning there are 2³² possible addresses
2³² = 4,294,967,296
So, the total number of unique IPv4 addresses is 4,294,967,296.
Part b): Reserved Addresses Calculation:
If 10% of the addresses are reserved for special purposes:
10% of 4,294,967,296 = 10/100 x 4,294,967,296 = 429, 496,729.6
Since number of addresses must be whole, we around to 429,496,729.
Now the remaining usable addresses:
4,294,967,296 - 429,496,729 = 3,865,470,567
So, 3,865,470,567 IPv4 addresses are left for general use.