# davimoreira0/autonmap architecture

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

- Interactive diagram: https://gitdiagram.com/davimoreira0/autonmap
- Repository: https://github.com/davimoreira0/autonmap

## Overview

AutoNmap is a single-file, interactive terminal wrapper for Nmap. The user selects one of 13 predefined scan profiles, supplies a target, and the program builds and executes the corresponding command, then pauses before returning to the menu. Startup checks that Nmap is available. All internal components share setup.py; the README documents the scan-profile capabilities, while the source excerpt shows the execution flow.

Main entry points: [`setup.py`](https://github.com/davimoreira0/autonmap/blob/main/setup.py) (Menu Loop)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_user(("Operator"))
node_app["Menu Loop<br/>[setup.py]"]
node_check["Nmap Check<br/>[setup.py]"]
node_profiles["Scan Profiles<br/>[setup.py]"]
node_target["Target Prompt<br/>[setup.py]"]
node_scan["Scan Runner<br/>[setup.py]"]
node_nmap["Nmap CLI"]

node_user -->|"chooses profile"| node_app
node_app -->|"checks availability"| node_check
node_app -->|"displays options"| node_profiles
node_app -->|"prompts target"| node_target
node_app -->|"runs selection"| node_scan
node_scan -->|"reads command"| node_profiles
node_scan -->|"executes command"| node_nmap

click node_app "https://github.com/davimoreira0/autonmap/blob/main/setup.py"
click node_check "https://github.com/davimoreira0/autonmap/blob/main/setup.py"
click node_profiles "https://github.com/davimoreira0/autonmap/blob/main/setup.py"
click node_target "https://github.com/davimoreira0/autonmap/blob/main/setup.py"
click node_scan "https://github.com/davimoreira0/autonmap/blob/main/setup.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_user,node_nmap toneIndigo
class node_app,node_check,node_profiles,node_target,node_scan toneTeal
```

## Components

### Other components

- **Operator**
- [Menu Loop](https://github.com/davimoreira0/autonmap/blob/main/setup.py): `setup.py`
- [Nmap Check](https://github.com/davimoreira0/autonmap/blob/main/setup.py): `setup.py`
- [Scan Profiles](https://github.com/davimoreira0/autonmap/blob/main/setup.py): `setup.py`
- [Target Prompt](https://github.com/davimoreira0/autonmap/blob/main/setup.py): `setup.py`
- [Scan Runner](https://github.com/davimoreira0/autonmap/blob/main/setup.py): `setup.py`
- **Nmap CLI**

## Connections

- Operator → Menu Loop: chooses profile (evidence: `setup.py`)
- Menu Loop → Nmap Check: checks availability (evidence: `setup.py`)
- Menu Loop → Scan Profiles: displays options (evidence: `setup.py`)
- Menu Loop → Target Prompt: prompts target (evidence: `setup.py`)
- Menu Loop → Scan Runner: runs selection (evidence: `setup.py`)
- Scan Runner → Scan Profiles: reads command (evidence: `setup.py`)
- Scan Runner → Nmap CLI: executes command (evidence: `setup.py`)
