# vinyamg/webcrawl architecture

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

- Interactive diagram: https://gitdiagram.com/vinyamg/webcrawl
- Repository: https://github.com/vinyamg/webcrawl

## Overview

WebCrawler is a command-line web-enumeration tool for authorized pentest and bug-bounty work. The main workflow accepts a target URL, crawls pages and JavaScript, and saves discovered resources and form fields to a per-target SQLite database; users can then select saved data in an interactive shell to inspect endpoints, parameters, subdomains, social links, and file types. JavaScript analysis adds endpoint, token, request, input, and sink detection. The sampled files show the main entry points and persistence calls; some analysis details are documented in the README but their complete implementation was not sampled.

Main entry points: [`funcionalidades/Crawler.py`](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/Crawler.py) (Crawler), [`funcionalidades/shell_analyse.py`](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/shell_analyse.py) (Analysis shell), [`funcionalidades/db.py`](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/db.py) (Target database), [`webcrawl.py`](https://github.com/vinyamg/webcrawl/blob/main/webcrawl.py) (CLI options)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["CLI and shell"]
  node_cli["CLI options<br/>[webcrawl.py]"]
  node_interactive["Analysis shell<br/>[shell_analyse.py]"]
end

subgraph group_collection["Crawling"]
  node_crawler["Crawler<br/>[Crawler.py]"]
  node_crawlconfig["Crawl configuration<br/>[config.py]"]
end

subgraph group_storage["Collected data"]
  node_database[("Target database<br/>[db.py]")]
end

subgraph group_analysis["Enumeration analysis"]
  node_enumeration["Resource enumeration<br/>[funcoes.py]"]
  node_jsanalysis["JavaScript analysis<br/>[funcoes.py]"]
end

node_operator(("Operator"))
node_target(("Web target"))
node_proxy(("Proxy service"))

node_operator -->|"starts"| node_cli
node_cli -->|"starts crawl"| node_crawler
node_cli -->|"opens analysis"| node_interactive
node_crawler -->|"uses settings"| node_crawlconfig
node_crawler -->|"requests pages"| node_target
node_crawler -.->|"routes requests"| node_proxy
node_crawler -->|"saves crawl data"| node_database
node_interactive -->|"opens target data"| node_database
node_interactive -->|"dispatches commands"| node_enumeration
node_interactive -->|"dispatches JS command"| node_jsanalysis
node_enumeration -->|"queries collected data"| node_database
node_jsanalysis -->|"reads JavaScript"| node_database

click node_cli "https://github.com/vinyamg/webcrawl/blob/main/webcrawl.py"
click node_interactive "https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/shell_analyse.py"
click node_crawler "https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/Crawler.py"
click node_crawlconfig "https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/config.py"
click node_database "https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/db.py"
click node_enumeration "https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/funcoes.py"
click node_jsanalysis "https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/funcoes.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_cli,node_interactive toneBlue
class node_crawler,node_crawlconfig toneAmber
class node_database toneMint
class node_enumeration,node_jsanalysis toneRose
class node_operator,node_target,node_proxy toneIndigo
```

## Components

### CLI and shell

- [CLI options](https://github.com/vinyamg/webcrawl/blob/main/webcrawl.py): `webcrawl.py`
- [Analysis shell](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/shell_analyse.py): `funcionalidades/shell_analyse.py`

### Crawling

- [Crawler](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/Crawler.py): `funcionalidades/Crawler.py`
- [Crawl configuration](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/config.py): `funcionalidades/config.py`

### Collected data

- [Target database](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/db.py): `funcionalidades/db.py`

### Enumeration analysis

- [Resource enumeration](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/funcoes.py): `funcionalidades/funcoes.py`
- [JavaScript analysis](https://github.com/vinyamg/webcrawl/blob/main/funcionalidades/funcoes.py): `funcionalidades/funcoes.py`

### Other components

- **Operator**
- **Web target**
- **Proxy service**

## Connections

- Operator → CLI options: starts (evidence: `README.md`)
- CLI options → Crawler: starts crawl (evidence: `webcrawl.py`)
- CLI options → Analysis shell: opens analysis (evidence: `webcrawl.py`)
- Crawler → Crawl configuration: uses settings (evidence: `funcionalidades/Crawler.py`)
- Crawler → Web target: requests pages (evidence: `funcionalidades/Crawler.py`)
- Crawler → Proxy service: routes requests
- Crawler → Target database: saves crawl data (evidence: `funcionalidades/Crawler.py`)
- Analysis shell → Target database: opens target data (evidence: `funcionalidades/shell_analyse.py`)
- Analysis shell → Resource enumeration: dispatches commands (evidence: `funcionalidades/shell_analyse.py`)
- Analysis shell → JavaScript analysis: dispatches JS command (evidence: `funcionalidades/shell_analyse.py`)
- Resource enumeration → Target database: queries collected data (evidence: `funcionalidades/funcoes.py`)
- JavaScript analysis → Target database: reads JavaScript (evidence: `funcionalidades/funcoes.py`)
