Fundamentals of Information Technology · 10 min read

Computer networks

A computer network is a group of interconnected devices that share data and resources. Networks are built from layers of protocols described by reference models (OSI and TCP/IP), interconnected by devices such as hubs, switches and routers over guided or wireless media, and protected by security measures. This note gives a foundation-level picture of each.

Key concepts

Networking models – layered design breaks a complex communication task into smaller, independent functions. Each layer serves the layer above and uses the layer below; peer layers communicate through protocols. Data is encapsulated going down (headers added) and decapsulated going up.

OSI model (ISO, 7 layers)

#LayerSignificanceData unit / examples
7ApplicationNetwork services to user appsHTTP, FTP, SMTP, DNS
6PresentationTranslation, encryption, compressionJPEG, SSL/TLS, ASCII
5SessionEstablish/manage/terminate sessions, checkpointsNetBIOS, RPC
4TransportEnd-to-end delivery, segmentation, reliability, portsSegment – TCP, UDP
3NetworkLogical (IP) addressing, routingPacket – IP, ICMP
2Data linkFraming, MAC addressing, error detectionFrame – Ethernet, PPP
1PhysicalBits on medium, voltages, connectorsBit – cables, hubs

TCP/IP model – 4 layers: Application (OSI 5–7), Transport (TCP/UDP), Internet (IP), Network access/Link (OSI 1–2). It is the practical model used by the Internet; OSI is a reference model.

Networking devices

DeviceOSI layerFunction
NIC1–2Connects computer to network; has MAC address
Repeater1Regenerates signal
Hub1Broadcasts to all ports; shared collision domain
Bridge2Connects two LAN segments; filters by MAC
Switch2Sends frame only to destination port using MAC table
Router3Connects different networks; forwards by IP; chooses best path
GatewayAllConnects dissimilar networks/protocols
Modem1Modulates/demodulates for telephone/cable lines

Transmission media

  • Guided (wired): twisted pair (UTP/STP; Cat5e/Cat6; RJ-45 connector; cheap; up to ~100 m), coaxial cable (cable TV, BNC), optical fibre (light pulses; highest bandwidth, long distance, immune to electromagnetic interference; single-mode and multimode).
  • Unguided (wireless): radio waves (Wi-Fi, FM), microwaves (terrestrial line-of-sight towers, satellite), infrared (remote controls, short range), Bluetooth.

Protocols and standards – a protocol is a set of rules: syntax (format), semantics (meaning), timing (when and how fast). Standards ensure interoperability; de jure (by official bodies) vs de facto (by wide use). Bodies: ISO, ITU-T, IEEE (802.3 Ethernet, 802.11 Wi-Fi), IETF (RFCs), ANSI, EIA/TIA. Common protocols: TCP, UDP, IP, HTTP, HTTPS, FTP, SMTP, POP3, IMAP, DNS, DHCP, ARP.

Network security

  • Goals: confidentiality, integrity, availability (CIA), authentication, non-repudiation.
  • Attacks: passive (eavesdropping, traffic analysis) and active (masquerading, replay, modification, denial of service). Others: phishing, malware (virus, worm, Trojan, ransomware, spyware), man-in-the-middle, password attacks, SQL injection.
  • Cryptography: converts plaintext to ciphertext. Symmetric (one shared secret key – DES, AES); asymmetric (public/private key pair – RSA). Hashing (SHA) for integrity; digital signatures for authentication and non-repudiation.
  • Firewalls: hardware or software that filters traffic between trusted and untrusted networks using rules; types – packet filtering, stateful inspection, proxy/application gateway.
  • Other measures: antivirus, IDS/IPS, VPN, strong passwords and MFA, regular updates, backups.
  • In Nepal, the Electronic Transactions Act 2063 (2008) addresses cybercrime and digital signatures.

High-yield points

  • OSI = 7 layers (ISO); TCP/IP = 4 layers.
  • Data units: bit (L1), frame (L2), packet (L3), segment (L4).
  • Hub/repeater = L1, switch/bridge = L2, router = L3.
  • Protocol elements: syntax, semantics, timing.
  • Symmetric = one shared key (DES, AES); asymmetric = key pair (RSA).
  • Firewall types: packet filter, stateful inspection, proxy/application gateway.

Exam tips

  • OSI top-down mnemonic: "All People Seem To Need Data Processing".
  • Router = network layer (IP); switch and bridge = data link (MAC); hub and repeater = physical.
  • Encryption/compression belong to the presentation layer.
  • Optical fibre is immune to electromagnetic interference.
  • Symmetric encryption uses one key; asymmetric uses a public–private pair.

Exam-style questions

From Calmon's question bank, which has 25 questions on this topic.

1. A group of 10 users wants every pair of users to communicate secretly using a separate symmetric key for each pair. How many keys are needed?

  • A. 20
  • B. 45
  • C. 100
  • D. 90

Answer: B. Number of pairs =n(n−1)/2=10×9/2=45= n(n-1)/2 = 10 \times 9/2 = 45 keys. (With public-key cryptography only 2n=202n = 20 keys would be needed.)

2. The application layer of the TCP/IP model corresponds to which OSI layers?

  • A. Session and transport layers
  • B. Application layer only
  • C. Application and presentation layers
  • D. Application, presentation and session layers

Answer: D. TCP/IP merges the functions of the OSI application, presentation and session layers into its single application layer.

Practise ASoE01 questions →

read it. practise it. pass it.

a free account adds chapter-wise practice, mock tests in the real exam pattern and a daily study plan.

create free account →