How karimelmasry42/ns3-rba-vanet-reproducibility works
Purpose and Integration Model
This is an overlay for a pinned ns-3-dev revision, not a standalone application. It reproduces VANET scaling measurements for proof-bearing vehicle-to-RSU authentication over IEEE 802.11p. The overlay is copied into an ns-3 tree; no src/ changes are required. Primary experiment source: scratch/rba-paper-scaling.cc. Build integration depends on scratch/CMakeLists.txt (referenced by the README but absent from the supplied tree).
Entry Points
• Simulation executable: the ns-3 scratch target built from scratch/rba-paper-scaling.cc; accepts topology, timing, beacon interval, and CSV-output arguments.
• Sweep orchestrator: tools/rba/run-scaling.sh; builds if needed, selects vehicle-count schedules, repeats runs, and coordinates aggregation/plotting.
• Analysis/visualization: tools/rba/plot-scaling.py; consumes run-level CSV data to produce grouped node-count summaries and SVG figures.
Simulation Topology and Wireless Boundary
scratch/rba-paper-scaling.cc creates only wireless vehicle OBUs and RSUs. Vehicles move on a multi-lane highway, choose the nearest RSU from initial position, and retain that association. Communications use 802.11p ad hoc networking, fixed communication range, and an OFDM 6 Mbps/10 MHz PHY mode. The modeled network boundary is a single vehicle-prover → RSU-verifier wireless hop.
Authentication Workload Mapping
The simulation represents each vehicle transmission as a fixed-size authenticated payload containing pseudonym identifiers, a compressed Sigma-style ZK proof, timestamp, and signature. Vehicle-side proof/signing and RSU-side verification/eligibility work are modeled as fixed processing-delay constants rather than executable cryptography. Logical TA, pseudonym list, RSU key ledger, blockchain, consensus, and feedback/reputation-update paths are explicitly outside ns-3 node and airtime modeling.
Relevant implementation path: scratch/rba-paper-scaling.cc.
Measurement and Result Semantics
FlowMonitor-derived packet counts and one-way wireless delay drive per-run metrics. Packet loss is computed from transmitted versus received packets; reported RBA end-to-end delay adds fixed prover and verifier processing delays to measured network delay. The simulator appends one row per run to a configured CSV; the result schema also captures topology, radio/payload settings, timing windows, offered load, and wall-clock duration.
Committed example artifacts establish expected output contracts:
• results/rba/rba-scaling-summary.csv
• results/rba/rba-node-count-summary.csv
Sweep, Aggregation, and Plot Pipeline
tools/rba/run-scaling.sh is the control-plane pipeline: it resolves explicit, uniform, or segmented vehicle-count schedules; executes repeated seeded simulations; manages FlowMonitor XML retention; and writes/merges run data. It then invokes tools/rba/plot-scaling.py to group observations by vehicle count, calculate descriptive statistics, and render packet-loss and authenticated-delay scaling figures. Plot artifacts are generated outputs, not simulation inputs.
Runtime and External Dependencies
The material runtime is C++ on ns-3-dev at the documented pinned commit, configured and built with CMake. Batch execution requires a POSIX shell; post-processing requires Python and its plotting/data dependencies as used by tools/rba/plot-scaling.py. There are no live TA, blockchain, cloud, database, or web-service dependencies: those roles are abstract protocol context only.
Main entry points: rba-paper-scaling.cc RBA scaling simulation · plot-scaling.py Scaling analysis and plots · run-scaling.sh Scaling sweep runner · rba-scaling-summary.csv Scaling summary CSV
Components 15
ns-3 simulation
- Pinned ns-3-dev · Host tree and CMake build environment for the overlay.
- RBA scaling simulation · Creates the VANET experiment and appends one CSV row per run.
scratch/rba-paper-scaling.cc - Vehicle OBUs · Mobile highway nodes retain their initially nearest RSU association.
scratch/rba-paper-scaling.cc - RSUs · Static verifier nodes perform modeled eligibility and verification work.
scratch/rba-paper-scaling.cc - 802.11p ad hoc hop · Fixed-range 6 Mbps/10 MHz OFDM vehicle-to-RSU communication.
scratch/rba-paper-scaling.cc - Authenticated payload workload · Fixed payload contains pseudonym, compressed ZK proof, timestamp, and signature.
scratch/rba-paper-scaling.cc - Fixed auth processing delays · Prover signing and verifier processing replace executable cryptography.
scratch/rba-paper-scaling.cc - FlowMonitor metrics · Derives packet counts, wireless delay, loss, and RBA end-to-end delay.
scratch/rba-paper-scaling.cc - Scratch target registration · Required scratch build registration referenced by the README.
Sweep and analysis
- Scaling sweep runner · Builds, schedules vehicle counts, repeats seeded runs, and manages FlowMonitor XML.
tools/rba/run-scaling.sh - Scaling analysis and plots · Groups observations, calculates statistics, and renders SVG figures.
tools/rba/plot-scaling.py
Results
- Run-level CSV · Per-run metrics plus topology, radio, timing, load, and duration fields.
- Scaling summary CSV
results/rba/rba-scaling-summary.csv - Node-count summary CSV
results/rba/rba-node-count-summary.csv - Scaling SVG figures · Packet-loss and authenticated-delay scaling plots.
Connections 19
- Pinned ns-3-dev → Scratch target registration: configures
- Scratch target registration → RBA scaling simulation: builds target
- Scaling sweep runner → Pinned ns-3-dev: builds if needed
- Scaling sweep runner → RBA scaling simulation: executes repeated runs
- Vehicle OBUs → 802.11p ad hoc hop: prover transmissions
- 802.11p ad hoc hop → RSUs: single-hop delivery
- Authenticated payload workload → Vehicle OBUs: models transmitted payload
- Authenticated payload workload → Fixed auth processing delays: maps crypto to delays
- Fixed auth processing delays → RSUs: models verification work
- RBA scaling simulation → Vehicle OBUs: creates and moves
- RBA scaling simulation → RSUs: creates and associates
- RBA scaling simulation → FlowMonitor metrics: collects flow data
- FlowMonitor metrics → Run-level CSV: appends per-run row
- Scaling sweep runner → Run-level CSV: writes and merges
- Scaling sweep runner → Scaling analysis and plots: invokes
- Run-level CSV → Scaling analysis and plots: consumes observations
- Scaling analysis and plots → Scaling summary CSV: writes summaries
- Scaling analysis and plots → Node-count summary CSV: groups by vehicle count
- Scaling analysis and plots → Scaling SVG figures: renders