The agent communicates with tools through two channels: most tools are MCP tools served byDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/SanMuzZzZz/LuaN1aoAgent/llms.txt
Use this file to discover all available pages before exploring further.
tools/mcp_service.py, while a small set of local tools are handled directly inside core/executor.py without any MCP round-trip. Every tool returns a JSON string. The executor calls these tools during the Execution phase of the P-E-R loop.
Local tools bypass the MCP transport layer and are resolved in-process by the executor. Currently only
query_causal_graph is a local tool. All other tools listed here are MCP tools served by tools/mcp_service.py.Metacognitive tools
These tools do not perform external actions. They force the executor into structured thinking steps, improving reasoning quality and traceability.think
Records a structured reasoning trace. Use this to analyze a situation before choosing an action, or to surface a knowledge gap when stuck.
A brief analysis of the current situation or context.
The specific problem to solve or decision to make.
Ordered list of reasoning steps leading to the conclusion.
The final conclusion or next action derived from the reasoning.
The last 50
think entries are retained in memory during a session. This history is not currently injected back into the executor prompt — the primary value is forcing structured deliberation before acting.formulate_hypotheses
Systematically proposes attack hypotheses when the executor is stuck. Use this before trying a new approach to ensure the decision is explicit and traceable.
List of hypothesis objects. Each object must contain:
reflect_on_failure
Performs structured root-cause analysis after a tool call fails. The prompt instructs the executor to produce a corrected action immediately after calling this tool.
The full action object that failed, including
tool and params keys.The exact error message returned by the failed tool.
expert_analysis
Async. Escalates a hard problem to a dedicated LLM call configured with a world-class security researcher system prompt. Use after at least two failed retrieve_knowledge attempts, or for problems involving unknown algorithms, complex regex bypasses, or black-box protocol reversal.
A clear, specific question for the expert. Pseudocode is accepted.
Supporting data: code snippets, token strings, error messages, request/response samples, failed retrieval keywords.
Execution and control tools
complete_mission
Signals that the top-level task goal has been fully achieved. Calling this tool writes a halt file to /tmp/{task_id}.halt, which the agent’s monitor loop detects to terminate all running subtasks immediately.
Detailed explanation of why the mission is complete.
Key evidence: shell output, database contents, captured flag, API response, etc.
The current task’s unique ID (available in the executor’s context).
- Obtained shell access on the target system
- Extracted sensitive data from a target database
- Captured a CTF flag
- Successfully demonstrated the existence of a critical vulnerability
query_causal_graph (local tool)
Queries the in-process causal graph directly without MCP transport. This zero-latency local tool lets the executor look up already-established evidence, confirmed vulnerabilities, and hypothesis state without making a network call.
This is a local tool — it does not appear in
mcp.json and does not go through the MCP service. It is handled directly by core/executor.py via _handle_local_tool.Filter results by node type. Common values:
Evidence, Hypothesis, ConfirmedVulnerability, Exploit. If omitted, all node types are returned.Substring search applied to the combined
title, description, vulnerability, and hypothesis fields of each node. Case-insensitive. If omitted, all nodes matching the node_type filter are returned.Maximum number of nodes to return.
Network and HTTP tools
http_request
Async. The preferred method for all HTTP interactions. Backed by a persistent httpx.AsyncClient session that automatically manages cookies across requests.
Use
http_request for single, exploratory requests. For repetitive testing (fuzzing, blind injection, brute force), use python_exec with a requests.Session instead.The target URL.
HTTP method:
GET, POST, PUT, DELETE, PATCH, etc.Request headers as key-value pairs. To send
Cookie, Authorization, or X-Requested-With, you must specify them here explicitly.Request body. Accepts a URL-encoded string or a dict of form fields.Content-Type resolution:
- If
headerscontainsContent-Type, it takes priority. - If
datais a dict andContent-Typeisapplication/json, the dict is serialized as JSON. - Otherwise defaults to
application/x-www-form-urlencoded.
Request timeout in seconds. Default tool timeout is 60 s (overridden by
TOOL_TIMEOUT_HTTP).Whether to follow HTTP redirects automatically. Accepts boolean or equivalent strings (
"true", "false", "1", "0").When
true (POST/PUT/PATCH only), disables URL/form encoding and sends the body exactly as provided. Use this when payloads contain characters that must not be percent-encoded (e.g., XSS angle brackets).concurrency_test
Async. Sends multiple requests simultaneously using asyncio.gather to test for race conditions, TOCTOU vulnerabilities, and atomic lock failures.
Target URL.
HTTP method.
Request body as a JSON string. Parsed to a dict if valid JSON.
Request headers as a JSON string.
Number of simultaneous requests. Maximum is 50 to prevent accidental DoS.
Shell and scripting tools
shell_exec
Async. Executes a shell command in a subprocess, streaming stdout+stderr in real time. Do not use this tool to call tools that are already exposed as MCP tools (e.g., dirsearch).
The shell command to execute (e.g.,
"ls -al /var/www").error_type values
| Value | Meaning |
|---|---|
RUNTIME | Non-zero exit for a general reason |
MISSING_TOOL | Command or binary not found |
SYNTAX | Invalid argument syntax detected |
python_exec
Async. Executes a Python script in a thread pool executor. The script runs with a pre-populated session (requests.Session) that inherits cookies from the shared httpx session. Cookie changes made inside the script are synced back to the global session after execution.
A self-contained Python script. Use
print() to produce output. The execution environment pre-injects requests, session (a requests.Session with inherited cookies), and json.error_type values
| Value | Meaning |
|---|---|
SYNTAX | Python SyntaxError |
IMPORT | Missing module |
RUNTIME | Exception raised during execution |
A concurrency lock serializes
python_exec calls to prevent sys.stdout patching conflicts. Parallel subtasks calling python_exec at the same time will queue.Knowledge tools
retrieve_knowledge
Async. Performs semantic search over the local knowledge base (attack techniques, WAF bypass methods, vulnerability exploitation guides, tool usage references). Queries are sent to the knowledge service HTTP API.
Search query using specific technical terms (e.g.,
"LFI path traversal", "SQL injection WAF bypass").Number of top results to return. Range: 1–10.
Knowledge service URL. Defaults to
KNOWLEDGE_SERVICE_URL from config (typically http://127.0.0.1:8081).distill_knowledge
Async. Writes a newly discovered insight into the permanent skill library (AgentSkills). Call this immediately after successfully overcoming a challenge, not just at the end of a task.
Detailed summary of the insight. Should include: problem background, obstacles encountered, specific bypass/exploitation method (including payloads), and analysis of why the approach succeeded.
web_search
Async. Searches DuckDuckGo for vulnerability details, CVE disclosures, exploit techniques, or general documentation. Falls back to direct HTML scraping if the duckduckgo-search package is not installed.
Search query (e.g.,
"CVE-2023-1234 exploit github", "SQL injection WAF bypass techniques").Number of results to return. Maximum recommended: 10.
Security scanner tools
sqlmap_tool
Async. Runs sqlmap to detect and exploit SQL injection vulnerabilities. Always uses --batch --random-agent flags for non-interactive execution.
Target URL with injectable parameter (e.g.,
"http://target.com/page.php?id=1"). Either url or raw_request_file is required.Path to a file containing a raw HTTP request (alternative to
url). Useful when the injection point is in a POST body or a custom header.Comma-separated tamper script names (e.g.,
"space2comment,randomcase"). Used to bypass WAF/IDS filters.Test thoroughness level (1–5). Higher values test more injection points and payloads.
Risk of tests (1–3). Higher values include potentially destructive payloads.
Force the backend DBMS (e.g.,
"mysql", "postgresql"). Skips DBMS detection.Additional sqlmap CLI arguments passed through
shlex.split (e.g., "--dump -T users").TOOL_TIMEOUT_SQLMAP).
dirsearch_scan
Async. Runs dirsearch to enumerate web directories and files. Incompatible arguments across dirsearch versions are automatically filtered and replaced.
Target URL (e.g.,
"http://target.com:8080").Comma-separated list of file extensions to scan for.
Additional
dirsearch CLI arguments. Note: --recursive-level and --recursion-level are automatically replaced with -r for version compatibility.TOOL_TIMEOUT_DIRSEARCH).
Exploit intelligence tools
search_exploit
Async. Queries NVD (National Vulnerability Database) and Exploit-DB for known vulnerabilities and public exploit code. Use this when you identify a software component and its version number.
Search terms (e.g.,
"canto wordpress 3.0.4", "apache 2.4.49").Optional direct CVE lookup (e.g.,
"CVE-2023-3452").Maximum number of results to return.
view_exploit
Async. Reads the full source of an Exploit-DB exploit using searchsploit. Use after search_exploit returns an edb_id.
Exploit-DB ID (e.g.,
"51826"). Either edb_id or path is required.Direct local filesystem path to an exploit file.
Maximum lines of exploit code to return.
Payload server tools
These tools manage a lightweight HTTP server for OOB (out-of-band) callbacks in RFI, XXE, and SSRF scenarios.start_payload_server
Async. Starts a background HTTP server on a randomly chosen port in the range 18000–18999 (or a specified port). All incoming requests are logged.
Route configuration list. Each entry:
Specific port to listen on. If omitted, a free port in 18000–18999 is selected automatically.
stop_payload_server
Async. Stops a running payload server.
The
server_id returned by start_payload_server.get_payload_server_logs
Async. Retrieves all requests received by a payload server. Use this to confirm OOB callbacks (SSRF/XXE).
The
server_id returned by start_payload_server.list_payload_servers
Async. Lists all currently active payload servers.
Nuclei scanner tools
nuclei_scan
Async. Runs Nuclei template-based vulnerability scanning against a target.
Target URL (e.g.,
"http://localhost:8080").Template path or name (e.g.,
"cves/2023/CVE-2023-3452.yaml" or "wordpress").Comma-separated severity filter:
critical, high, medium, low, info.Comma-separated tag filter (e.g.,
"cve,wordpress,rce").Total scan timeout in seconds.
Maximum requests per second.
Number of concurrent template executions.
nuclei_list_templates
Async. Lists available Nuclei templates, with optional filtering by search terms, tags, and severity.
Keyword filter (e.g.,
"wordpress canto", "CVE-2023").Tag filter.
Severity filter.
Maximum number of templates to return.
Tool timeouts
Default tool-level timeouts are configured inconf/config.py and can be overridden with environment variables.
| Tool | Default timeout | Environment variable |
|---|---|---|
sqlmap_tool | 600 s | TOOL_TIMEOUT_SQLMAP |
nuclei_scan | 300 s | TOOL_TIMEOUT_NUCLEI |
dirsearch_scan | 300 s | TOOL_TIMEOUT_DIRSEARCH |
python_exec | 300 s | TOOL_TIMEOUT_PYTHON |
concurrency_test | 180 s | TOOL_TIMEOUT_CONCURRENCY |
shell_exec | 120 s | TOOL_TIMEOUT_SHELL |
http_request | 60 s | TOOL_TIMEOUT_HTTP |
expert_analysis | 60 s | TOOL_TIMEOUT_EXPERT |
web_search | 30 s | TOOL_TIMEOUT_WEB_SEARCH |
think / formulate_hypotheses / reflect_on_failure | 30 s | TOOL_TIMEOUT_THINK etc. |
retrieve_knowledge | 15 s | TOOL_TIMEOUT_RETRIEVE |