# rk-000/kali-commander architecture

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

- Interactive diagram: https://gitdiagram.com/rk-000/kali-commander
- Repository: https://github.com/rk-000/kali-commander

## Overview

Kali Commander is a browser-based interface for assembling Kali Linux tool commands; it generates commands for users to copy and run, rather than executing them itself. The documented workflow is to browse categories, open a tool page, select options and a target, configure output, then copy the generated command. The graph includes the catalog, tool-page experience, command composition, and browser utilities. Source excerpts confirm catalog rendering and navigation, command-building behavior, and browser storage; page-to-builder wiring and several advertised capabilities are documented in the README but their implementations were not sampled.

Main entry points: [`js/command-builder.js`](https://github.com/rk-000/kali-commander/blob/main/js/command-builder.js) (Command builder), [`pages`](https://github.com/rk-000/kali-commander/tree/main/pages) (Tool pages), [`js/main.js`](https://github.com/rk-000/kali-commander/blob/main/js/main.js) (Category browser), [`index.html`](https://github.com/rk-000/kali-commander/blob/main/index.html) (Homepage)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_catalog["Tool catalog"]
  node_homepage["Homepage<br/>[index.html]"]
  node_catalog_ui["Category browser<br/>[main.js]"]
  node_tool_data["Tool catalog data<br/>[tools-data.js]"]
end

subgraph group_tool_ui["Tool interface"]
  node_tool_pages["Tool pages"]
  node_shared_template["Shared page template<br/>[template.html]"]
  node_wpscan_page["WPScan page<br/>[wpscan.html]"]
  node_harvester_page["theHarvester page<br/>[theharvester.html]"]
end

subgraph group_command["Command composition"]
  node_builder["Command builder<br/>[command-builder.js]"]
  node_generated_command["Generated command<br/>[command-builder.js]"]
end

subgraph group_browser["Browser utilities"]
  node_utils["Validation and utilities<br/>[utils.js]"]
  node_local_storage[("Browser local storage")]
  node_clipboard["Browser clipboard"]
end

node_user(("User"))
node_kali(("Kali Linux"))

node_user -->|"opens"| node_homepage
node_homepage -->|"loads"| node_catalog_ui
node_catalog_ui -->|"reads categories"| node_tool_data
node_catalog_ui -->|"navigates"| node_tool_pages
node_user -->|"selects tool"| node_tool_pages
node_tool_pages -->|"uses shared template"| node_shared_template
node_tool_pages -->|"configures options"| node_builder
node_wpscan_page -.->|"supports command generation"| node_builder
node_harvester_page -.->|"supports command generation"| node_builder
node_builder -->|"generates"| node_generated_command
node_builder -->|"saves and loads"| node_local_storage
node_builder -->|"copies command"| node_clipboard
node_tool_pages -.->|"uses validation"| node_utils
node_user -->|"copies command"| node_generated_command
node_user -->|"runs command"| node_kali

click node_homepage "https://github.com/rk-000/kali-commander/blob/main/index.html"
click node_catalog_ui "https://github.com/rk-000/kali-commander/blob/main/js/main.js"
click node_tool_data "https://github.com/rk-000/kali-commander/blob/main/js/tools-data.js"
click node_tool_pages "https://github.com/rk-000/kali-commander/tree/main/pages"
click node_shared_template "https://github.com/rk-000/kali-commander/blob/main/pages/template.html"
click node_wpscan_page "https://github.com/rk-000/kali-commander/blob/main/pages/wpscan.html"
click node_harvester_page "https://github.com/rk-000/kali-commander/blob/main/pages/theharvester.html"
click node_builder "https://github.com/rk-000/kali-commander/blob/main/js/command-builder.js"
click node_generated_command "https://github.com/rk-000/kali-commander/blob/main/js/command-builder.js"
click node_utils "https://github.com/rk-000/kali-commander/blob/main/js/utils.js"

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_homepage,node_catalog_ui,node_tool_data,node_user toneBlue
class node_tool_pages,node_shared_template,node_wpscan_page,node_harvester_page toneAmber
class node_builder,node_generated_command toneMint
class node_utils,node_local_storage,node_clipboard toneRose
class node_kali toneIndigo
```

## Components

### Tool catalog

- [Homepage](https://github.com/rk-000/kali-commander/blob/main/index.html): `index.html`
- [Category browser](https://github.com/rk-000/kali-commander/blob/main/js/main.js): `js/main.js`
- [Tool catalog data](https://github.com/rk-000/kali-commander/blob/main/js/tools-data.js): `js/tools-data.js`

### Tool interface

- [Tool pages](https://github.com/rk-000/kali-commander/tree/main/pages): `pages`
- [Shared page template](https://github.com/rk-000/kali-commander/blob/main/pages/template.html): `pages/template.html`
- [WPScan page](https://github.com/rk-000/kali-commander/blob/main/pages/wpscan.html): `pages/wpscan.html`
- [theHarvester page](https://github.com/rk-000/kali-commander/blob/main/pages/theharvester.html): `pages/theharvester.html`

### Command composition

- [Command builder](https://github.com/rk-000/kali-commander/blob/main/js/command-builder.js): `js/command-builder.js`
- [Generated command](https://github.com/rk-000/kali-commander/blob/main/js/command-builder.js): `js/command-builder.js`

### Browser utilities

- [Validation and utilities](https://github.com/rk-000/kali-commander/blob/main/js/utils.js): `js/utils.js`
- **Browser local storage**
- **Browser clipboard**

### Other components

- **User**
- **Kali Linux**

## Connections

- User → Homepage: opens (evidence: `README.md`)
- Homepage → Category browser: loads (evidence: `README.md`)
- Category browser → Tool catalog data: reads categories (evidence: `js/main.js`)
- Category browser → Tool pages: navigates (evidence: `js/main.js`)
- User → Tool pages: selects tool (evidence: `README.md`)
- Tool pages → Shared page template: uses shared template (evidence: `README.md`)
- Tool pages → Command builder: configures options (evidence: `README.md`)
- WPScan page → Command builder: supports command generation
- theHarvester page → Command builder: supports command generation
- Command builder → Generated command: generates (evidence: `js/command-builder.js`)
- Command builder → Browser local storage: saves and loads (evidence: `js/command-builder.js`)
- Command builder → Browser clipboard: copies command (evidence: `js/command-builder.js`)
- Tool pages → Validation and utilities: uses validation
- User → Generated command: copies command (evidence: `README.md`)
- User → Kali Linux: runs command (evidence: `README.md`)
