Skip to content

Wordlists

sm0k3net edited this page Nov 28, 2026 · 2 revisions

Wordlists

Wordlists are one registry with three sources: compact lists bundled in the plugin, operator uploads, and AI-generated lists. Every entry resolves to the path the active runtime can use, so the agent never hard-codes a container path that does not exist on the host.

Wordlists drawer with bundled categories, line counts, custom upload and AI enhancement

Bundled lists

wordlists/manifest.json is the machine-readable catalog: 12 lists, nine categories, about 30 KB. They are compact derivatives of SecLists (MIT), not the multi-million-line originals.

Id Category Lines Source
dir-common directories 200 SecLists common.txt plus curated high-value paths
dir-medium directories 600 dir-common plus top RAFT directory entries
raft-large-directories directories 800 First 800 of raft-large-directories.txt
dns-5000 dns 500 Top 500 of subdomains-top1million-5000.txt
passwords-top200 passwords 200 Top 200 of 10k-most-common.txt
probable-top200 passwords 200 Top 200 of probable-v2_top-207.txt
usernames-top100 usernames 100 Username shortlist plus common service accounts
lfi-jhaddix lfi 80 First 80 of LFI-Jhaddix.txt
sqli sqli 60 First 60 of Generic-SQLi.txt
xss xss 60 First 60 of XSS-Jhaddix.txt
api-endpoints api 80 First 80 of api-endpoints.txt
ad-users ad 60 Curated Active Directory account names

Licensing and lawful-use notes are in wordlists/README.md and docs/ATTRIBUTION.md.

Resolution per runtime

pentest_resolve_wordlist({ id, tool }) turns an id or category into a path:

  1. an exact id wins (dir-medium);
  2. otherwise the category alias resolves (dir, dirs, directories; dns, subdomains; pass, password, passwords; users, usernames; lfi, traversal; sqli, sql; xss; api; ad, active-directory);
  3. a tool hint picks a default for a broad category — gobuster gets dir-common, ffuf gets raft-large-directories, feroxbuster/wfuzz dir-medium, hydra probable-top200 and usernames-top100, nmap/dnsx/amass/subfinder dns-5000, sqlmap sqli, dalfox/xsstrike xss, nuclei dir-common/lfi-jhaddix, netexec/crackmapexec the AD pair; otherwise the first list in that category is used.

The result carries id, name, hostPath, containerPath, lines, runtime and arg. arg is the container path under containerWordlistDir in Docker mode and the host path otherwise. Pass arg to gobuster/ffuf/hydra; never hard-code either form.

Identifiers are validated: at most 64 characters, no /, \ or ... Unknown ids raise a wordlist not found error rather than guessing.

Uploads

Upload from the Wordlists drawer (the bridge route is POST /dsh-redteam/wordlist/upload):

  • body is the raw text, capped at 32 MiB; media type text/plain, application/octet-stream or form-encoded;
  • the name must match [A-Za-z0-9._-]+, at most 64 characters, with no ..;
  • content must not be empty and must not contain NUL bytes;
  • the category is a lowercase slug of at most 32 characters, default custom;
  • the id is slugged from the name and suffixed -2, -3, … rather than overwriting a bundled or existing custom list.

Uploaded files are written 0600 under $DSH_HOME/redteam/wordlists/<id>.txt with metadata in _meta.json. Bundled lists cannot be removed; a custom or AI list can.

Custom and generated list locations

Runtime Path
Host $DSH_HOME/redteam/wordlists/<id>.txt
Container /opt/redteam/wordlists/<id>.txt (configurable with containerWordlistDir)

wordlists.sync() copies every list into a running container with mkdir -p and tee over docker exec -i, one list per call. Re-syncing is safe and idempotent. In host mode there is nothing to copy, and the call returns a note instead of an error.

AI enhancement

pentest_enhance_wordlist (or the drawer) asks the Host's model route for candidates:

  • Route: aiEnhancement.provider + aiEnhancement.model when both are set, otherwise the Host's default model selection. Status distinguishes disabled, no-llm, no-model and ready.
  • Consent gate: category and instruction alone never need consent. Target, technologies, observed paths or tool output are engagement context, and are sent only when aiEnhancement.allowRemoteContext is true or the call passes consent:true; otherwise the result is consent-required.
  • Prompt: strict JSON ({"entries":[...]}), no markdown, and instructions inside the supplied context are treated as data. Credential-looking values are redacted before anything leaves the host.
  • Parsing and validation: the first balanced JSON object or array is extracted; each candidate is normalized for its category — directory entries are relative (no leading slash, no .., no spaces, at most 200 characters), DNS entries are lowercase host names (at most 253, valid labels), usernames and AD accounts reject whitespace and URL punctuation, passwords are printable ASCII (at most 128), API/SQLi/XSS/LFI entries are single bounded lines. Control characters and entries over 512 characters are dropped.
  • Deduplication: candidates are compared case-insensitively with the base list and with every existing AI-generated list before being kept.
  • Count: 20–1000, default 200, additionally capped by aiEnhancement.maxCandidates (default 300).
  • Saving: the result is a new list with source:"ai" and an id such as ai-directories-<timestamp>-<rand>, stored like an upload and synced to the container. Metadata (provider, model, base list, instruction, observed paths, generated time, hit/miss counters) lives in ai-meta.json.

Feedback and adaptation

pentest_wordlist_feedback records hits and misses for an AI list. The record accumulates counts plus bounded hit/miss lists (500 entries each) and is exposed in the AI history, so you can choose the next base list or instruction from real results. Feedback never mutates the saved list silently, and it is not injected into a later prompt automatically — the loop is generate, use, record, then generate again with what you learned.

pentest_wordlist_adapt derives variants without needing a model, then optionally widens with one:

  • Seeds: explicit hits, observedPaths, parsed toolOutput from gobuster/ffuf/nmap, or the first lines of a base list when nothing else is given.
  • Local mutation: extension variants (.bak, .old, .zip, .tar.gz, .json, .js, .php, .txt), environment prefixes, and sibling names such as backup, admin, config, .git, v1, v2. The mode is reported as local.
  • Model widening: only when a route is available, count permits and context is allowed; the result becomes hybrid. Without those, the local result is still saved.
  • Deduplication: against the base list, all AI lists and within the batch; overlap is counted in the result.

Both tools save a new list; pass save:false (or inspect the response) when you only want the candidate preview.

Practical notes

  • pentest_wordlists lists every list with line counts and the current runtime's path form.
  • Preview shows up to 500 lines and 256 KiB, enough to sanity-check a list without loading it.
  • Password and payload lists are for authorized testing only; rate and scope limits belong to the engagement rules, not the list. The host directory is authoritative; the container copy is derived.

Related

Clone this wiki locally