This task is for the project CROSSFIT (Content-aware Routing Over Standard Service For Interactive Technologies) initiative.
The goal is to demonstrate a simplified authoritative DNS server that dynamically steers traffic for XR applications based on latency measurements.
Traditional DNS and BGP cannot adapt to real time performance changes. This prototype DNS server:
- Periodically measures latency to two backend servers.
- Selects the lowest latency server dynamically.
- Answers DNS queries for
snl-columbia-university.github.iowith that server’s IP. - Logs all measurements, queries, and responses.
- Active latency measurement every 10 seconds
- Returns best server IP dynamically
- Configurable DNS port via
--portflag - Logs include:
- Ping results
- Incoming queries
- Outgoing responses
- Python 3.8+
dnsliblibrary
Install dependencies:
pip install dnslib
## 🚀 How to Run
## Run on standard DNS port (requires root/sudo):
sudo python3 crossfit_dns.py --port 53
## OR ##
## Run on custom port (no root needed, e.g., 8053):
python3 crossfit_dns.py --port 8053
## 🔧 How to Test
## If running on port 53:
dig @127.0.0.1 snl-columbia-university.github.io
## OR ##
## If running on custom port (e.g., 8053):
dig @127.0.0.1 -p 5353 snl-columbia-university.github.io
