This repository contains the full set of assignments completed as part of the CS341: Computer Networks Laboratory course. The project is divided into five progressively complex modules, each exploring key aspects of computer networking through simulation, protocol implementation, monitoring, and performance analysis.
This project presents a hands-on implementation of key computer networking principles including:
- Application-layer protocols (HTTP, DNS)
- Proxy and caching mechanisms
- Congestion control
- Router-level scheduling
- Routing algorithms
- Wired vs Wireless collision management (CSMA/CD & CSMA/CA)
Each module is implemented in Python or C++, using raw sockets or simulation tools such as ns-3, and validated via real traffic patterns or simulations.
cs341-networking-project/
├── Assignment2_HTTP_Proxy_DNS/
├── Assignment3_Drone_Weather_TCP_UDP/
├── Assignment4_Scheduling_iSLIP/
├── Assignment5_Distance_Vector_Routing/
├── Assignment6_NS3_CSMA_CD_CA/
└── README.md
- Python (3.8+) – socket programming, threading
- C++ with ns-3 – discrete event simulation
- Wireshark & tcpdump – traffic capture and inspection
- Matplotlib – performance graphing
- Linux/WSL – development environment
- Clone this repo:
git clone https://github.com/yourusername/cs341-networking-project.git
- Navigate to a module: cd Assignment1_HTTP_Proxy_DNS
- Follow the instructions in each folder's README.
- For ns-3 simulations: Make sure ns-3 is installed. Build and run simulations from the Assignment5_NS3_CSMA_CD_CA directory.
- Analyzed live HTTP traffic using Wireshark.
- Implemented recursive DNS resolution and an LRU-caching HTTP proxy using sockets.
- Extended proxy with session-level cookie management and analytics.
- Developed a tri-mode communication stack for drones (control, telemetry, and file transfer).
- Simulated real-time weather data streaming with TCP Reno-style congestion control and compression.
- Simulated an 8×8 input/output router switch.
- Implemented and compared:
- Priority Scheduling
- Weighted Fair Queuing
- Round Robin
- iSLIP (iterative matching)
- Analyzed metrics: throughput, latency, fairness, drop rate.
- Built a complete DVR simulator handling topology changes.
- Implemented count-to-infinity prevention using:
- Poisoned Reverse
- Split Horizon
- Simulated edge failures and routing table stabilization.
- Used ns-3 to simulate:
- Ethernet (CSMA/CD) with collision and backoff behavior.
- Wi-Fi (CSMA/CA) in a 5×5 ad-hoc grid with UDP flows.
- Ran experiments with and without RTS/CTS to compare throughput and drop rate.
Course: CS342 – Computer Networks Lab
Institution: IIT Guwahati
Year: 2024