Overview
This repository contains my project work for CS6501: Network Security and Privacy, Spring 2026.
The project is built on top of ns-3 and focuses on simulation code for network monitoring and anomaly-related experiments. The repository includes custom ns-3 modules under src/ and experiment programs under scratch/.
All source code in this repository was written by the repository author as original course work. The code itself was not generated by AI.
Repository Layout
setup-ns3.sh: downloads and builds ns-3.37, then links this repository’ssrc/andscratch/directories into the ns-3 treescratch/anomalyPrediction/anomalyPrediction.cc: main experiment programscratch/aodvExample.cc: additional ns-3 example codesrc/database/: database support modulesrc/sha256/: SHA-256 utility modulesrc/nodeInfo/: node metadata helper modulesrc/timestamp/: timestamp helper modulepython/python.ipynb: notebook workspace for analyze script.
Prerequisites
The current dependency list appears to target an Arch Linux environment:
paru -S cmake python dpdk qt5-base openmpi sqlite libxml2 boost boost-libs glib2 libpcap gsl gtk3 goocanvas python-gobject python-cairo python-pygraphviz ipython clang llvm castxml python-pygccxml python-cxxfilt python-setuptools python-pip python-wheel git mercurial doxygen graphviz imagemagick python-sphinx texlive-bin wgetYou will also need standard build tools and internet access for downloading ns-3 and fetching libpqxx during the build.
Setup
Run the setup script from the repository root:
chmod +x setup-ns3.sh
./setup-ns3.shThe script will:
- Download
ns-allinone-3.37if it is not already present - Extract the archive
- Build ns-3
- Symlink this repository’s
scratch/files into the ns-3scratch/directory - Symlink this repository’s
src/modules into the ns-3src/directory
Running Experiments
After setup completes, move into the generated ns-3 directory and run the experiment from there.
Example:
cd ns-allinone-3.37/ns-3.37
./ns3 run "anomalyPrediction --pcap=false --printRoutes=true --numOfUAVs=3 --time=3 --step=1 --EnableMonitor=true --hostname=test --dataRate=1Mbps"Notes
setup-ns3.shis the project setup script for ns-3- The database module uses
libpqxxfor PostgreSQL connectivity - This repository is intended for course and research use in CS6501