Computer Networks
Computer Networks
MCA205
Data Communication
Imagine Jitter in networking is like inconsistent postal delivery times: just as letters
sent at regular intervals might arrive at varying times due to factors like traffic, data
packets sent over a network can experience varying delays in arrival due to network
congestion or routing changes.
In applications like video conferencing or online gaming, high jitter can lead to
issues like choppy audio/video or lag, as the "flow" of data packets isn't smooth and
consistent.
The Five components of a Data Communication System
1. Message
2. Sender
3. Receiver
4. Transmission Medium
5. Protocol
Data Representation
● Text
● Numbers
● Image
● Audio
● Video
Data flow between two devices
● Simplex Communication: Data transmission is one-way only, like a radio
broadcast where information flows from the station to listeners, but listeners
cannot respond back to the station.
Example:
1. When we turn on Wi-Fi on our device (like a smartphone or laptop), it sends out a broadcast message to all nearby
networks, asking for information. This is like shouting in a room and asking if there are any Wi-Fi networks available.
2. Every Wi-Fi router (or access point) within range that receives this broadcast message will respond with information
about its network, such as the network name (SSID, Service Set Identifier).
SSID: https://byjus.com/gate/ssid-full-form/
Another example of broadcast is the DHCP process, where a device sends a broadcast message to find a DHCP
server when it connects to a network. DHCP ? We will learn more about it. Feel free to investigate.
Homework 1
1. What is a Protocol ?
(Understand Protocol in digital communication as a conceptual framework or set of
guidelines. It is not a piece of software, hardware.)
2. What is RFC ? Who publishes it ?
3. What is RFC 766 and RFC 2616?
https://www.ietf.org/rfc/rfc959.txt (Request for Comments: 765, FTP)
https://www.ietf.org/rfc/rfc2616.txt (Request for Comments: 2616, HTTP)
4. The Internet Engineering Task Force (IETF) ? What is that ?
5. Understand Scope of IETF's Work.
6. List other Standards Organizations.
7. List some popular HTTP libraries available for various programming languages.
8. List some popular FTP libraries available for various programming languages.
Quick basics to ponder over 02.02.2024
1. IP Address (Private-Public: LAN-Internet)
Internet Assigned Numbers Authority (IANA): IANA oversees the global IP address
allocation
2. Host name and Domain Name ( LAN, Internet)
3. Host name examples ( workstation-01, server-01, CR’s Laptop (CR’s personal laptop
connected to the network), Donald Trump’s Laptop etc.)
4. Domain Name examples ( facebook.com, google.com, example.com ): Human readable
names
5. FQDN ( Fully Qualified domain name) : Combination of hostname and domain name : For
instance, if a server named "server01" is part of the "example.com" domain, its FQDN
would be "server01.example.com".
6. Domain Name System ( DNS) : Translates human-readable domain names (like
www.example.com) into IP addresses that computers use to identify each other on the
network: The internet's phonebook. ICANN
Public - Private IPs 02.02.2024
1. IP Address (Private-Public: LAN-Internet)
Private IPs are used within a local network (e.g., home or office) for device communication.
Example: Devices in a home network (192.168.0.x).
Public IPs are unique addresses assigned to devices on the public internet, allowing them
to be directly accessed from anywhere. Example: The public IP of a web server that anyone
can access. ( Let us check what is the public IP of Google.com)
2. Public IPs: Assigned by Internet Service Providers (ISPs) to your modem/router for internet
communication.
3. Private IPs: Assigned by a router within a local network (e.g., DHCP) for internal
communication.
4. Public IPs: Internet Assigned Numbers Authority (IANA): IANA oversees the global IP
address allocation
DHCP (Dynamic Host Configuration Protocol) is a network management protocol used to automatically
assign IP addresses to devices on a network.
Port Numbers
● Port Numbers: Help direct network traffic to the appropriate application or service on
a device. They act as endpoints for communication.
● Range: Port numbers range from 0 to 65535*, resulting in a total of 65,536 possible
ports. (A port number is a 16-bit unsigned integer, which means it consists of 16
binary digits or bits)
● Well-Known Ports: Port numbers from 0 to 1023 are reserved for well-known
services and protocols. For example, port 80 is reserved for HTTP (web traffic), port
25 is used for SMTP (email), and port 22 is used for SSH (secure shell).
● Registered Ports: Port numbers from 1024 to 49151 are registered ports, which are
assigned to specific applications or services by the Internet Assigned Numbers
Authority (IANA).
● Dynamic or Private Ports: Port numbers from 49152 to 65535 are considered
dynamic or private ports. They are available for use by applications but are not
officially registered.
MAC Address: Each NIC has a unique identifier known as a MAC (Media
Access Control) address. This address is used to identify devices on a
local network and is essential for network communication.
Enhanced Network Efficiency and Performance: By creating a separate collision domain for each connected
device, switches reduce network congestion and collisions, significantly improving network performance.
Operates at OSI Model's Data Link Layer: Functioning at the data link layer (Layer 2) of the OSI model, switches
use MAC addresses to learn device locations and efficiently route data to the correct destination. Some
advanced switches can also operate at the network layer (Layer 3), performing routing functions.
5. Bridges
Network Segmentation Device: A bridge is a network device
used to divide a larger network into smaller, more
manageable segments, or to connect multiple network
segments, improving performance and organization. (
Provides connection between LANs)
Note: Public IP Address: This is a unique address used across the entire
internet. It's assigned by Internet Service Providers (ISPs) and ensures that
a device can be uniquely identified and accessed from anywhere on the
internet.
Private IP Address: This is used within a local network (like a home or office
network) and isn't unique across the entire internet. Devices within the same
local network use private IP addresses to communicate with each other.
These addresses are not directly accessible from the internet.
7. Gateways
Network Connecting Device: A gateway is a
networking hardware that acts as a "gate" between
two networks, often different types of networks like
a local network and the internet.
Data Translation and Routing: It translates data
formats and protocols, allowing communication
between different systems, and routes network
traffic from one network to another.
Internet Access Enabler: In most home and office
settings, a gateway (often integrated into a router)
connects the local network to the internet,
managing data traffic and providing network
security.
Key Functions of a Gateway
Protocol Translation: Translates different network
protocols, enabling communication between
systems that use different protocols.
Converts Digital to Analog Signals: It converts digital data from a computer into analog signals that can be
transmitted over telephone lines or other communication mediums.
Enables Internet Connectivity: Modems are essential for connecting to the internet, particularly in settings
where broadband or fiber connections are not available.
Bidirectional Communication: It works in both directions, not only converting digital data from your
computer into analog for transmission (modulation) but also converting incoming analog signals back into
digital form (demodulation) for your computer to understand.
9. Firewalls
● A firewall is a network device or software that
controls network security and access rules.
● It is placed between secure internal networks
and potentially insecure external networks,
such as the Internet.
● Firewalls are usually set up to deny access
from unrecognized sources while permitting
activities from known ones.
Image Source: How Stuffs work
● The importance of firewalls in network security
is escalating due to the continual rise in cyber
attacks.
10. Physical Ports
● Nature: A physical port is a tangible interface on
networking devices like routers, switches, and
servers. It's a hardware-based point of connection
where network cables are plugged in.
Illustration of computer network types In increasing order of scale: • Nanoscale • Body (BAN) • Personal (PAN)
• Local (LAN) • Campus (CAN) • Metropolitan (MAN) • Radio access (RAN) • Wide (WAN) Click on the image
Network Protocols and standards
●
Network Models
●
Addressing
● A Quick Note: The Internetworking Protocol (IP) is the transmission
mechanism used by the TCP/IP protocols.
● This IP address has a limitation of not being able to address more than 256
computers (one octet only takes value between 0 to 255)
Components/Parts of an IP Address v4
● How can you address computers in a network
that has more than 256 computers?
What is the solution?
● What if '198.172' represents the network address and '168.10' represents the host
address? How many hosts per network can be addressed? How many networks can
be identified?
● What if only '198' represents the network address and '172.168.10' represents the
host address? What would be the possible number of hosts per network?
● Although 65,536 may appear as a large number in the context of a LAN, but there
literally hundreds of thousands of networks that interconnect together to form
internet. Therefore a compromise has to be reached between the number of octets
used for network and host addresses.
Classes of IP address
Classes of IP Address
● Class A
● Class B
● Class C
● Class D
● Class E
A quick note on subnet mask ( just for now …)
● A subnet mask helps you in determining which portion of an IP Address is
Network portion or ID and which portion is Host Portion or ID.
The "255.255.255" part of the subnet mask indicates the network portion, and
the "0" indicates the host portion.
Is not it ?
Answer is “No”. Let’s see Why…
Classes of IP Address : Class A
● The very first bit (the higher-order bit) of the first octet in Class A is always set
to 0. This is used to distinguish Class A addresses from other classes.
● Hence we remain with only 7 bits in the first octet to identify the network ID,
allowing for 2^7 (128) possible network identifiers (from 0000000 to 1111111 in
binary).
Classes of IP Address : Class A
● But in practice, the ranges from 0000000 (0 in decimal) to 1111110 (126 in decimal)
are used, as 00000000 (0.0.0.0) is reserved and 01111111 (127.0.0.0) is reserved
for loopback addresses.
● The remaining 24 bits are used for host addresses within each network, allowing for
2^24 (16,777,216) possible addresses.
● However, two addresses within each network are not usable for hosts: the network
address (where all host bits are 0) and the broadcast address (where all host bits
are 1). Therefore, the number of usable addresses is 2^24 - 2 = 16,777,214.
A quick important note…
● Usage: Used by large organizations and large ISPs with a large number of hosts.
● Leading Bits: 0
● Example: 10.0.0.1
Classes of IP Address: Class B
● The first two octets are used for the network address and last two octets are
used for the host address.
The Network ID is 16 bit long.
The Host ID is 16 bit long.
● The higher-order bits of the first octet of IP addresses of class B are always
set to 10. The remaining 14 bits are used to determine the network ID
Classes of IP Address: Class B
● The higher-order bits of the first octet of IP addresses of class C is always set
to 110, the remaining 21 bits are used to determine the network ID.
So, total number of Network addresses possible would be: 2^21 = 20,97,152 ,
and Host addresses: 2^8 – 2 = 254
Classes of IP Address: Class C
● Range: IP addresses belonging to class C range from
192.0.0.0 – 223.255.255.255.
● Default Subnet Mask: 255.255.255.0
● Notation: /24 (Indicates that the network portion of the address occupies the
first three octets.)
● Assignable IP Address Range for hosts: 192.0.0.1 to 223.255.254.254
● Usage: Small networks, like small businesses
● Leading Bits: 110
● Example: 192.168.0.1
Identify Network ID and Host ID: Q1
● Class A Example: 10.23.45.67
Network ID: 10
Host ID: 23.45.67
● Purpose: Reserved for multicast groups. These addresses are used for
one-to-many communication, with a single sender and multiple receivers.
● Subnet Mask: Not applicable, as these addresses are not used in traditional
host-to-host communications.
● Leading Bits: 1110
Classes of IP Address: Class E
● Range: 240.0.0.0 – 255.255.255.254
● Usage: These addresses are reserved for experimental purposes and should
not be used in production networks.
● Subnet Mask: Not applicable, as these addresses do not follow the standard
IP addressing scheme.
● Leading Bits: 1111
Classes of IP Address: A quick overview
(https://www.ibm.com/docs/he/networkmanager/4.2.0?topic=translation-private-address-ran
ges)
References
● Data Communications and Networking, Fourth Edition by Behrouz A.
Forouzan
● https://www.ietf.org/ The Internet Engineering Task Force (IETF)
● PHI - Basics of Networking
● The following site lists all RFCs, including those related to IP and TCP.
www.ietf.org/rfc.html
● www.acm.org/sigcomm/sos.html : This site gives the status of various
networking standards.