# kamalesh-sudo/neurosploit architecture

> Architecture diagram of the GitHub repository kamalesh-sudo/neurosploit, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/kamalesh-sudo/neurosploit
- Repository: https://github.com/kamalesh-sudo/neurosploit

## Overview

NeuroSploit is an interactive domain-reconnaissance framework with both a Textual console and a headless CLI. The workflow normalizes and validates a target, runs an asynchronous scan, enriches discovered live subdomains, and presents or exports a report. The README documents additional UI controls and optional nmap and local-LLM hooks. Some scan-stage orchestration and discovery details were not shown, so uncertain internal links are marked unverified rather than asserted.

Main entry points: [`neurosploit/core.py`](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py) (Async Recon Engine), [`neurosploit/tui.py`](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/tui.py) (TUI Console), [`neurosploit/cli.py`](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/cli.py) (CLI Entry), [`neurosploit/targets.py`](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/targets.py) (Target Hygiene)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["User Entry"]
  node_cli["CLI Entry<br/>[cli.py]"]
  node_console["TUI Console<br/>[tui.py]"]
  node_target_data["Default Targets<br/>[urls.txt]"]
end

subgraph group_workflow["Scan Workflow"]
  node_target_validation["Target Hygiene<br/>[targets.py]"]
  node_engine["Async Recon Engine<br/>[core.py]"]
end

subgraph group_enrichment["Recon Enrichment"]
  node_subdomain_discovery["Subdomain Discovery<br/>[core.py]"]
  node_crtsh(("crt.sh"))
  node_dns["DNS Resolution<br/>[core.py]"]
  node_http_probe["HTTP Fingerprinting<br/>[core.py]"]
  node_port_scan["Port Enrichment<br/>[core.py]"]
  node_nmap(("nmap"))
  node_ssl["TLS Certificate<br/>[core.py]"]
end

subgraph group_results["Results"]
  node_report_analysis["Report Analysis<br/>[core.py]"]
  node_report_export["Report Export<br/>[core.py]"]
  node_ai_prompt["LLM Prompt Hook"]
  node_report_file["JSON Report"]
end

node_user(("Operator"))

node_user -->|"starts"| node_cli
node_user -->|"uses"| node_console
node_cli -->|"normalizes and validates"| node_target_validation
node_cli -->|"runs headless scan"| node_engine
node_cli -->|"launches TUI"| node_console
node_console -->|"normalizes and validates"| node_target_validation
node_console -->|"loads default list"| node_target_data
node_console -->|"runs background scan"| node_engine
node_console -->|"exports report"| node_report_export
node_target_validation -->|"validates target"| node_engine
node_engine -.->|"discovers subdomains"| node_subdomain_discovery
node_subdomain_discovery -->|"queries"| node_crtsh
node_subdomain_discovery -.->|"resolves hosts"| node_dns
node_engine -.->|"probes live hosts"| node_http_probe
node_engine -.->|"enriches hosts"| node_port_scan
node_port_scan -.->|"optionally invokes"| node_nmap
node_engine -.->|"checks HTTPS certificates"| node_ssl
node_engine -->|"builds scan summary"| node_report_analysis
node_report_analysis -.->|"supports local LLM hooks"| node_ai_prompt
node_console -->|"renders results"| node_report_analysis
node_report_export -.->|"writes JSON"| node_report_file
node_cli -->|"optionally exports"| node_report_file

click node_cli "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/cli.py"
click node_console "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/tui.py"
click node_target_data "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/data/urls.txt"
click node_target_validation "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/targets.py"
click node_engine "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_subdomain_discovery "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_dns "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_http_probe "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_port_scan "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_ssl "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_report_analysis "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_report_export "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py"
click node_ai_prompt "https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/prompts/analysis_prompt.txt"

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_cli,node_console,node_target_data toneBlue
class node_target_validation,node_engine toneAmber
class node_subdomain_discovery,node_crtsh,node_dns,node_http_probe,node_port_scan,node_nmap,node_ssl toneMint
class node_report_analysis,node_report_export,node_ai_prompt,node_report_file toneRose
class node_user toneIndigo
```

## Components

### User Entry

- [CLI Entry](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/cli.py): `neurosploit/cli.py`
- [TUI Console](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/tui.py): `neurosploit/tui.py`
- [Default Targets](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/data/urls.txt): `neurosploit/data/urls.txt`

### Scan Workflow

- [Target Hygiene](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/targets.py): `neurosploit/targets.py`
- [Async Recon Engine](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`

### Recon Enrichment

- [Subdomain Discovery](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`
- **crt.sh**
- [DNS Resolution](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`
- [HTTP Fingerprinting](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`
- [Port Enrichment](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`
- **nmap**
- [TLS Certificate](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`

### Results

- [Report Analysis](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`
- [Report Export](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/core.py): `neurosploit/core.py`
- [LLM Prompt Hook](https://github.com/kamalesh-sudo/neurosploit/blob/main/neurosploit/prompts/analysis_prompt.txt): `neurosploit/prompts/analysis_prompt.txt`
- **JSON Report**

### Other components

- **Operator**

## Connections

- Operator → CLI Entry: starts (evidence: `README.md`)
- Operator → TUI Console: uses (evidence: `README.md`)
- CLI Entry → Target Hygiene: normalizes and validates (evidence: `neurosploit/cli.py`)
- CLI Entry → Async Recon Engine: runs headless scan (evidence: `neurosploit/cli.py`)
- CLI Entry → TUI Console: launches TUI (evidence: `neurosploit/cli.py`)
- TUI Console → Target Hygiene: normalizes and validates (evidence: `neurosploit/tui.py`)
- TUI Console → Default Targets: loads default list (evidence: `README.md`)
- TUI Console → Async Recon Engine: runs background scan (evidence: `neurosploit/tui.py`)
- TUI Console → Report Export: exports report (evidence: `neurosploit/tui.py`)
- Target Hygiene → Async Recon Engine: validates target (evidence: `neurosploit/core.py`)
- Async Recon Engine → Subdomain Discovery: discovers subdomains (evidence: `neurosploit/core.py`)
- Subdomain Discovery → crt.sh: queries (evidence: `neurosploit/core.py`)
- Subdomain Discovery → DNS Resolution: resolves hosts (evidence: `neurosploit/core.py`)
- Async Recon Engine → HTTP Fingerprinting: probes live hosts (evidence: `neurosploit/core.py`)
- Async Recon Engine → Port Enrichment: enriches hosts (evidence: `neurosploit/core.py`)
- Port Enrichment → nmap: optionally invokes
- Async Recon Engine → TLS Certificate: checks HTTPS certificates (evidence: `neurosploit/core.py`)
- Async Recon Engine → Report Analysis: builds scan summary (evidence: `neurosploit/core.py`)
- Report Analysis → LLM Prompt Hook: supports local LLM hooks
- TUI Console → Report Analysis: renders results (evidence: `neurosploit/tui.py`)
- Report Export → JSON Report: writes JSON
- CLI Entry → JSON Report: optionally exports (evidence: `neurosploit/cli.py`)
