How ractiurd/ghoulsight works
Purpose and Distribution
GhoulSight is a Linux-oriented XSS scanner distributed here as a prebuilt executable rather than source code. Its sole executable entry point is ghoulsight; README.md defines its CLI contract and operational requirements. No application source tree, dependency manifest, or deployment configuration is present.
CLI Control Plane
The binary accepts targets from a single URL, URL list, stdin, raw HTTP request, or domain crawl, then selects one or more scan modes (r, d, c, f). Major runtime controls include concurrency, timeout, crawl depth, headers, cookies, POST data, payload location, output file, probing, and reflection-only mode. Entry artifact: ghoulsight.
Target Acquisition and Discovery
Input normalization is the first major boundary: direct URLs and parsed raw requests supply explicit targets, while domain mode crawls links and forms to discover parameterized URLs. Crawling is depth-limited and extracts links plus GET/POST form inputs. Optional URL probing filters unreachable targets before scan work begins. The README documents this behavior in README.md; implementation is encapsulated in ghoulsight.
Scan Orchestration and Modes
A configurable thread pool processes targets and can combine reflected, DOM, context-aware, and fuzz scans. Smart-scan behavior stops further payload testing for a URL after its first confirmed XSS. Reflection caching avoids repeated parameter work, while a two-phase strategy tries custom payloads before fallback payloads for targets without findings. Primary runtime: Go 1.25+ binary ghoulsight.
Injection and Payload Engines
Reflected scanning tests query and POST parameters; path-based scanning identifies reflected URL segments and injects into them. DOM mode analyzes browser DOM sources and sinks. Context-aware mode identifies HTML, JavaScript, CSS, URL, and related contexts, dynamically creates payloads, and mutates them for breakout, encoding, grammar, and interaction variants. Fuzz mode replaces FUZZ positions across URLs, headers, cookies, and form data using single, cluster-bomb, or pitchfork strategies. Payload files are external user-managed inputs, conventionally under ~/.config/ghoulsight/payloads/.
Verification, Results, and External Boundaries
The scanner’s defining claim is execution-based confirmation rather than reflection-only reporting: it requires a locally installed Chromium-family browser (Chrome, Chromium, or Brave) to validate findings. Confirmed results produce PoC URLs/raw requests, progress reporting, and optional file output. Telegram bot integration provides setup and real-time scan/finding notifications. Relevant repository artifacts: ghoulsight, README.md.
Licensing and Persistent State
Execution is gated by a machine-bound subscription system: initial installations receive 300 trial runs, while activation keys grant 30-day access and expired subscriptions fall back to remaining trials. The README also describes persistent adaptive-learning state for successful mutation patterns, though its storage location and protocol are not exposed. A small switch.txt exists but has no documented architectural role.
Main entry points: ghoulsight Scan orchestrator · README.md CLI contract
Components 18
Inputs
- CLI control plane · Selects inputs, modes, and runtime controls.
ghoulsight - URLs, stdin & raw requests
ghoulsight - Domain crawl · Depth-limited link and form discovery.
ghoulsight - CLI contract · Documents operation and requirements.
README.md
Scanner Runtime
- Target normalization
ghoulsight - URL probe · Optionally removes unreachable targets.
ghoulsight - Scan orchestrator · Runs selected modes with smart-stop and reflection caching.
ghoulsight - Reflected & path scan · Tests query, POST, and reflected path segments.
ghoulsight - DOM scan · Analyzes DOM sources and sinks.
ghoulsight - Context-aware scan · Generates and mutates payloads by injection context.
ghoulsight - FUZZ scan · Expands FUZZ positions in requests and form data.
ghoulsight
Validation & Results
- Chromium-family browser · Executes payloads to confirm XSS.
- Execution confirmation · Distinguishes confirmed XSS from reflection-only results.
ghoulsight - PoCs & output · Emits progress, PoC URLs/raw requests, and optional files.
ghoulsight
External Services & State
- User payload files · Custom payloads precede fallback payloads.
- Telegram bot · Sends setup and real-time scan notifications.
ghoulsight - Subscription gate · Machine-bound trials and 30-day activations gate execution.
ghoulsight - Adaptive learning state · Stores successful mutation patterns; location is undisclosed.
ghoulsight
Connections 24
- CLI contract → CLI control plane: documents
- CLI control plane → URLs, stdin & raw requests: accepts
- CLI control plane → Domain crawl: starts
- URLs, stdin & raw requests → Target normalization: supplies targets
- Domain crawl → Target normalization: discovers targets
- Target normalization → URL probe: optional
- Target normalization → Scan orchestrator: targets
- URL probe → Scan orchestrator: reachable targets
- Subscription gate → CLI control plane: gates execution
- Scan orchestrator → Reflected & path scan: dispatches
- Scan orchestrator → DOM scan: dispatches
- Scan orchestrator → Context-aware scan: dispatches
- Scan orchestrator → FUZZ scan: dispatches
- User payload files → Reflected & path scan: custom payloads
- User payload files → Context-aware scan: payload source
- User payload files → FUZZ scan: payload source
- Adaptive learning state → Context-aware scan: mutation patterns
- Reflected & path scan → Execution confirmation: candidate findings
- DOM scan → Execution confirmation: candidate findings
- Context-aware scan → Execution confirmation: candidate findings
- FUZZ scan → Execution confirmation: candidate findings
- Execution confirmation → Chromium-family browser: executes in
- Execution confirmation → PoCs & output: confirmed findings
- PoCs & output → Telegram bot: notifies