# naren-kanchi/aura architecture

> Architecture diagram of the GitHub repository naren-kanchi/aura, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/naren-kanchi/aura
- Repository: https://github.com/naren-kanchi/aura

## Overview

AURA is a research testbed for cross-organisation federated network intrusion detection. Its main workflow prepares flow data and a shared model, trains organisation-local clients, aggregates model updates against a server-held root dataset, and records round decisions; the operations UI exposes detection and response controls. Separate evaluation branches cover Byzantine robustness and privacy attacks. The README documents several capabilities whose implementation was not sampled, so those links are shown as unverified rather than inferred from module names.

Main entry points: [`aura/fl_client.py`](https://github.com/naren-kanchi/aura/blob/main/aura/fl_client.py) (FL Clients), [`frontend/src/pages/DashboardPage.tsx`](https://github.com/naren-kanchi/aura/blob/main/frontend/src/pages/DashboardPage.tsx) (Operations Dashboard), [`aura/fl_server.py`](https://github.com/naren-kanchi/aura/blob/main/aura/fl_server.py) (FL Server), [`aura/detector.py`](https://github.com/naren-kanchi/aura/blob/main/aura/detector.py) (Anomaly Detection)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_detection["Detection and Response"]
  node_flows["Flow Data<br/>[data_loader.py]"]
  node_models["Detection Models<br/>[models.py]"]
  node_detector["Anomaly Detection<br/>[detector.py]"]
  node_explainer["AE Explainer<br/>[ae_explainer.py]"]
  node_response["Incident Response<br/>[response_engine.py]"]
  node_policy["Response Policy<br/>[policy_engine.py]"]
end

subgraph group_federation["Federated Learning"]
  node_clients["FL Clients<br/>[fl_client.py]"]
  node_server["FL Server<br/>[fl_server.py]"]
  node_audit[("Round Audit Log<br/>[blockchain.py]")]
end

subgraph group_operations["Operations UI"]
  node_dashboard["Operations Dashboard<br/>[DashboardPage.tsx]"]
  node_api["Dashboard API<br/>[api.ts]"]
  node_config["Config Hook<br/>[useConfig.ts]"]
  node_networkview["Network View<br/>[NetworkGraph.tsx]"]
  node_timeline["Score Timeline<br/>[ScoreTimeline.tsx]"]
  node_threatview["Threat Radar<br/>[ThreatRadar.tsx]"]
  node_api_server["Backend API<br/>[api_server.py]"]
end

subgraph group_evaluation["Research Evaluation"]
  node_byzantine["Byzantine Benchmark"]
  node_ablation["Ablation Sweep"]
  node_dlg["Gradient Inversion"]
  node_mia["Membership Inference<br/>[mia_attack.py]"]
  node_mitm["MITM Simulation<br/>[mitm_simulation.py]"]
end

node_operator(("Operator"))

node_operator -->|"uses"| node_dashboard
node_dashboard -->|"requests state"| node_api
node_dashboard -->|"reads settings"| node_config
node_config -->|"fetches config"| node_api
node_dashboard -->|"renders graph"| node_networkview
node_dashboard -->|"renders scores"| node_timeline
node_dashboard -->|"renders radar"| node_threatview
node_api -.->|"calls endpoints"| node_api_server
node_api_server -.->|"serves detection"| node_detector
node_flows -->|"loads partitions"| node_clients
node_models -.->|"trains locally"| node_clients
node_clients -->|"sends updates"| node_server
node_server -->|"records decisions"| node_audit
node_server -->|"uses root data"| node_flows
node_models -.->|"scores flows"| node_detector
node_detector -.->|"explains residuals"| node_explainer
node_detector -.->|"emits incidents"| node_response
node_response -->|"executes policy"| node_policy
node_clients -.->|"evaluated by"| node_byzantine
node_server -->|"evaluated by"| node_byzantine
node_models -->|"benchmarked by"| node_ablation
node_clients -.->|"updates analyzed"| node_dlg
node_clients -.->|"privacy evaluated"| node_mia
node_clients -.->|"hash checks simulated"| node_mitm

click node_flows "https://github.com/naren-kanchi/aura/blob/main/aura/data_loader.py"
click node_models "https://github.com/naren-kanchi/aura/blob/main/aura/models.py"
click node_detector "https://github.com/naren-kanchi/aura/blob/main/aura/detector.py"
click node_explainer "https://github.com/naren-kanchi/aura/blob/main/aura/ae_explainer.py"
click node_response "https://github.com/naren-kanchi/aura/blob/main/aura/response_engine.py"
click node_policy "https://github.com/naren-kanchi/aura/blob/main/policy_engine.py"
click node_clients "https://github.com/naren-kanchi/aura/blob/main/aura/fl_client.py"
click node_server "https://github.com/naren-kanchi/aura/blob/main/aura/fl_server.py"
click node_audit "https://github.com/naren-kanchi/aura/blob/main/aura/blockchain.py"
click node_dashboard "https://github.com/naren-kanchi/aura/blob/main/frontend/src/pages/DashboardPage.tsx"
click node_api "https://github.com/naren-kanchi/aura/blob/main/frontend/src/api.ts"
click node_config "https://github.com/naren-kanchi/aura/blob/main/frontend/src/useConfig.ts"
click node_networkview "https://github.com/naren-kanchi/aura/blob/main/frontend/src/components/NetworkGraph.tsx"
click node_timeline "https://github.com/naren-kanchi/aura/blob/main/frontend/src/components/ScoreTimeline.tsx"
click node_threatview "https://github.com/naren-kanchi/aura/blob/main/frontend/src/components/ThreatRadar.tsx"
click node_api_server "https://github.com/naren-kanchi/aura/blob/main/api_server.py"
click node_byzantine "https://github.com/naren-kanchi/aura/blob/main/scripts/benchmark_byzantine.py"
click node_ablation "https://github.com/naren-kanchi/aura/blob/main/scripts/benchmark_ablation.py"
click node_dlg "https://github.com/naren-kanchi/aura/blob/main/aura_attacks/gradient_inversion_attack.py"
click node_mia "https://github.com/naren-kanchi/aura/blob/main/aura_attacks/mia_attack.py"
click node_mitm "https://github.com/naren-kanchi/aura/blob/main/aura_attacks/mitm_simulation.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_flows,node_models,node_detector,node_explainer,node_response,node_policy toneBlue
class node_clients,node_server,node_audit toneAmber
class node_dashboard,node_api,node_config,node_networkview,node_timeline,node_threatview,node_api_server toneMint
class node_byzantine,node_ablation,node_dlg,node_mia,node_mitm toneRose
class node_operator toneIndigo
```

## Components

### Detection and Response

- [Flow Data](https://github.com/naren-kanchi/aura/blob/main/aura/data_loader.py): `aura/data_loader.py`
- [Detection Models](https://github.com/naren-kanchi/aura/blob/main/aura/models.py): `aura/models.py`
- [Anomaly Detection](https://github.com/naren-kanchi/aura/blob/main/aura/detector.py): `aura/detector.py`
- [AE Explainer](https://github.com/naren-kanchi/aura/blob/main/aura/ae_explainer.py): `aura/ae_explainer.py`
- [Incident Response](https://github.com/naren-kanchi/aura/blob/main/aura/response_engine.py): `aura/response_engine.py`
- [Response Policy](https://github.com/naren-kanchi/aura/blob/main/policy_engine.py): `policy_engine.py`

### Federated Learning

- [FL Clients](https://github.com/naren-kanchi/aura/blob/main/aura/fl_client.py): `aura/fl_client.py`
- [FL Server](https://github.com/naren-kanchi/aura/blob/main/aura/fl_server.py): `aura/fl_server.py`
- [Round Audit Log](https://github.com/naren-kanchi/aura/blob/main/aura/blockchain.py): `aura/blockchain.py`

### Operations UI

- [Operations Dashboard](https://github.com/naren-kanchi/aura/blob/main/frontend/src/pages/DashboardPage.tsx): `frontend/src/pages/DashboardPage.tsx`
- [Dashboard API](https://github.com/naren-kanchi/aura/blob/main/frontend/src/api.ts): `frontend/src/api.ts`
- [Config Hook](https://github.com/naren-kanchi/aura/blob/main/frontend/src/useConfig.ts): `frontend/src/useConfig.ts`
- [Network View](https://github.com/naren-kanchi/aura/blob/main/frontend/src/components/NetworkGraph.tsx): `frontend/src/components/NetworkGraph.tsx`
- [Score Timeline](https://github.com/naren-kanchi/aura/blob/main/frontend/src/components/ScoreTimeline.tsx): `frontend/src/components/ScoreTimeline.tsx`
- [Threat Radar](https://github.com/naren-kanchi/aura/blob/main/frontend/src/components/ThreatRadar.tsx): `frontend/src/components/ThreatRadar.tsx`
- [Backend API](https://github.com/naren-kanchi/aura/blob/main/api_server.py): `api_server.py`

### Research Evaluation

- [Byzantine Benchmark](https://github.com/naren-kanchi/aura/blob/main/scripts/benchmark_byzantine.py): `scripts/benchmark_byzantine.py`
- [Ablation Sweep](https://github.com/naren-kanchi/aura/blob/main/scripts/benchmark_ablation.py): `scripts/benchmark_ablation.py`
- [Gradient Inversion](https://github.com/naren-kanchi/aura/blob/main/aura_attacks/gradient_inversion_attack.py): `aura_attacks/gradient_inversion_attack.py`
- [Membership Inference](https://github.com/naren-kanchi/aura/blob/main/aura_attacks/mia_attack.py): `aura_attacks/mia_attack.py`
- [MITM Simulation](https://github.com/naren-kanchi/aura/blob/main/aura_attacks/mitm_simulation.py): `aura_attacks/mitm_simulation.py`

### Other components

- **Operator**

## Connections

- Operator → Operations Dashboard: uses
- Operations Dashboard → Dashboard API: requests state (evidence: `frontend/src/pages/DashboardPage.tsx`)
- Operations Dashboard → Config Hook: reads settings (evidence: `frontend/src/pages/DashboardPage.tsx`)
- Config Hook → Dashboard API: fetches config (evidence: `frontend/src/useConfig.ts`)
- Operations Dashboard → Network View: renders graph (evidence: `frontend/src/pages/DashboardPage.tsx`)
- Operations Dashboard → Score Timeline: renders scores (evidence: `frontend/src/pages/DashboardPage.tsx`)
- Operations Dashboard → Threat Radar: renders radar (evidence: `frontend/src/pages/DashboardPage.tsx`)
- Dashboard API → Backend API: calls endpoints
- Backend API → Anomaly Detection: serves detection
- Flow Data → FL Clients: loads partitions (evidence: `aura/fl_client.py`)
- Detection Models → FL Clients: trains locally (evidence: `aura/fl_client.py`)
- FL Clients → FL Server: sends updates
- FL Server → Round Audit Log: records decisions
- FL Server → Flow Data: uses root data
- Detection Models → Anomaly Detection: scores flows
- Anomaly Detection → AE Explainer: explains residuals
- Anomaly Detection → Incident Response: emits incidents (evidence: `aura/response_engine.py`)
- Incident Response → Response Policy: executes policy (evidence: `aura/response_engine.py`)
- FL Clients → Byzantine Benchmark: evaluated by
- FL Server → Byzantine Benchmark: evaluated by
- Detection Models → Ablation Sweep: benchmarked by (evidence: `aura_attacks/ablation_sweep.py`)
- FL Clients → Gradient Inversion: updates analyzed
- FL Clients → Membership Inference: privacy evaluated
- FL Clients → MITM Simulation: hash checks simulated
