X-Ways MCP
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@X-Ways MCP validate XWFIM cache at C:\xwfim\Temp"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
X-Ways MCP Server
An MCP server for X-Ways Forensics triage, installation validation, and controlled automation.
This repo follows the same general idea as bethington/ghidra-mcp: put a
specialist desktop analysis tool behind a structured MCP surface so agents can
inspect state, run repeatable workflows, and keep a useful audit trail. The first
version is intentionally a safe control plane. When command-line or scripting
coverage is not enough, runners should generate a small X-Tension bridge for the
specific in-process gap and document the API provenance for future runs.
Current Capabilities
Discover X-Ways Forensics, WinHex, X-Ways Imager, and XWFIM executables.
Validate XWFIM
Tempdownloads and detect truncated ZIPs such as a badviewer.zip.Hash evidence and downloaded packages with MD5/SHA-1/SHA-256.
Create repeatable case workspace folders.
Build read-only triage inventories for mounted folders or exports.
Run a forensic harness that writes case manifests, report stubs, status JSON, and audit logs compatible with
Donovoi/forensic-copilot.Create disposable synthetic test environments for Windows, Linux, macOS, and generic evidence fixtures.
Build X-Ways launch commands without executing them.
Optionally launch X-Ways when explicitly enabled.
Fetch public X-Ways release information for quick version checks.
Cache and search the X-Ways manual locally for command-line, scripting, and headless workflow syntax.
Plan X-Ways operations with a headless-first, native-distributed-RVS, X-Tension-next, UI-last policy.
Generate local X-Tension bridge scaffolds with API notes and build hooks.
Inventory X-Ways executable imports, delay imports,
XWF_*exports, andXWF_*/XT_*string clues with documented PowerShell cmdlets.Expose the 77 verified
XWF_*exports as agent-facing PowerShell cmdlets that create validated JSONL requests for an in-process X-Tension bridge.Plan parallel X-Ways processing from the local manual: native distributed volume snapshot refinement first, isolated worker cases only as fallback.
Provide a reusable PowerShell guardrail module for container-first exports, manual/action gates, and contemporaneous notes.
Prefer query-first X-Ways analysis through command-line/script, Export List metadata, X-Tensions, reports, or bounded UI before materializing file contents.
Run read-only X-Ways case database usage-pattern triage from metadata strings, with sanitized reports and local-only alias maps.
Provide a loose case-run manifest contract so examiner harnesses such as
Donovoi/forensic-copilotcan consume sanitized X-Ways outputs without becoming tightly coupled to this repo.Maintain a generic best-practice catalog so notes can record which jurisdiction/SOP guidance was followed and why.
Related MCP server: Sift MCP (Docker edition)
Safety Model
Read-only and dry-run behavior is the default.
launch_xways will not execute unless both conditions are true:
XWAYS_MCP_ALLOW_EXECUTE=1the tool call passes
confirm=true
This avoids accidentally starting analysis, imaging, or script workflows while an agent is still planning.
Automation preference is:
Manual first: check the newest available X-Ways manual, official docs, or approved local docs cache before deciding command syntax, API behavior, distributed processing, X-Tension work, or UI fallback.
X-Ways command-line, scripts, saved dialog selections,
Cfg:,XT:, andXTParam:*.X-Ways native distributed RVS for different evidence objects in the same case when the manual supports it.
A generated X-Tension bridge when the task needs in-process X-Ways access or the API covers something the headless surface cannot.
UI automation only as a bounded last resort.
If a runner uses documented or undocumented X-Tensions API behavior, it must record the symbols, X-Ways version constraints, and provenance in local bridge notes before using the bridge on real evidence.
X-Ways analysis is query-first. Use command-line/script routes, Export List metadata, reports, X-Tensions, or bounded UI queries when they can answer the question without materializing file contents. File-content exports are container-first only when bytes must leave X-Ways for external tooling. Metadata-only lists can be exported for planning, but copied/recovered file contents must first go into an X-Ways evidence file container.
Requirements
Python 3.10+
X-Ways Forensics, WinHex, X-Ways Imager, or XWFIM installed separately
Windows for real X-Ways launching and executable version inspection
The server itself can run on other platforms for archive validation, hashing, and folder inventory work.
Quick Start
python -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install -e ".[dev]"
pytest
python -m xways_mcp --transport stdioCache the current X-Ways manual locally for offline model lookup:
python -m pip install -e ".[dev]"
python -c "from xways_mcp.manual import cache_xways_manual; print(cache_xways_manual(source=r'<XWAYS_ROOT>\manual.pdf'))"To refresh from the public X-Ways manual and official scripting/setup pages:
python -c "from xways_mcp.manual import cache_xways_manual; print(cache_xways_manual(download_latest=True, fetch_official_docs=True, refresh=True))"Run the MCP stdio smoke test:
python scripts\smoke_mcp.py --search-root "<XWFIM_ROOT>" --public-releaseRun a forensic-copilot-compatible harness preflight:
python -m xways_mcp.harness xwfim-preflight `
--case-name CASE-001 `
--xwfim-root "<XWFIM_ROOT>" `
--staging-root artifacts `
--output-root reports `
--evidence-os Windows `
--evidence-mode portable-toolingRun a local query-first usage-pattern triage over an existing X-Ways case database without exporting file contents:
.\scripts\Invoke-XwfCaseDbPathStringTriage.ps1The script writes a sanitized report, structured JSON, and a sensitive local-only alias map under the local case workspace reports folder.
Compare a local X-Ways executable surface against the committed XWF/XT reference baseline:
Import-Module .\powershell\XWaysForensicWorkflow\XWaysForensicWorkflow.psd1 -Force
Compare-XwfExternalSurface `
-XwfRoot "<XWF_ROOT>" `
-OutputDirectory ".\reports\xwf-external-surface"The comparison writes Markdown, JSON, and CSV artifacts for imports, delay imports, exports, API-like strings, and undocumented-looking string candidates.
Create validated XWF API bridge requests with the generated PowerShell cmdlets:
Import-Module .\powershell\XWaysForensicWorkflow\XWaysForensicWorkflow.psd1 -Force
Get-XwfItemName -Argument @{ nItemID = 42 }
Add-XwfComment `
-Argument @{ nItemID = 42; lpComment = 'Reviewed'; nFlagsHowToAdd = 0 } `
-OutboxPath ".\case-workspaces\CASE-001\xwf-api-requests.jsonl" `
-AllowMutatingThese cmdlets do not call X-Ways exports directly from PowerShell. They produce
xwf-api-bridge-request/v1 objects for an in-process X-Tension bridge.
Build disposable synthetic fixtures for every supported evidence OS:
python -m xways_mcp.testenv build --name CASE-001 --evidence-os all --root test-envs --force
python -m xways_mcp.testenv destroy --name CASE-001 --evidence-os all --root test-envs --missing-okConfigure your MCP client with:
{
"mcpServers": {
"xways-mcp": {
"command": "python",
"args": ["-m", "xways_mcp", "--transport", "stdio"],
"env": {
"XWAYS_HOME": "C:\\xwf",
"XWAYS_MCP_SEARCH_ROOTS": "<XWAYS_ROOT>;<XWFIM_ROOT>",
"XWAYS_MCP_ALLOW_EXECUTE": "0",
"PYTHONIOENCODING": "utf-8"
}
}
}
}Useful Tools
environmentpublic_xways_releasemanual_statuscache_xways_manualsearch_xways_manualheadless_xways_referenceplan_xways_operationplan_parallel_xways_jobscreate_xtension_scaffolddiscover_installationsinspect_xwfim_cachevalidate_archivehash_filecreate_workspacetriage_inventorybuild_launch_commandlaunch_xwaysharness_init_caseharness_xwfim_preflightharness_folder_triagetestenv_createtestenv_buildtestenv_runtestenv_destroytestenv_list
See docs/TOOLS.md for details.
See docs/FORENSIC_COPILOT.md for integration with
Donovoi/forensic-copilot.
See docs/INTEGRATION_CONTRACT.md for the loose
adapter contract and shared case-run manifest.
See docs/TEST_ENVIRONMENTS.md for disposable
synthetic fixture testing.
See docs/MANUAL_FIRST.md for the manual-first tooling
policy.
See docs/HEADLESS_XWAYS.md for local manual indexing
and headless command lookup.
See docs/PARALLEL_PROCESSING.md for the
manual-backed distributed processing policy.
See docs/XTENSION_BRIDGE.md for the generated
X-Tension bridge workflow.
See docs/EXTERNAL_SURFACE_ANALYSIS.md for
PE import/export/string analysis and the XWF 21.8 x64 baseline.
See docs/XWF_API_CMDLETS.md for the generated
PowerShell wrappers over the verified XWF_* exports.
See docs/FORENSIC_SOUNDNESS.md for the
container-first export policy and reusable PowerShell module.
See docs/BEST_PRACTICES.md for the public
best-practice catalog and selection workflow.
XWFIM Validation Example
inspect_xwfim_cache(path="<XWFIM_ROOT>")This reports each ZIP in Temp, whether it can be opened, and whether the ZIP
end-of-central-directory record is missing. That is the signal for a truncated
download.
Roadmap
Stabilize the Python MCP control plane.
Add stronger X-Ways script templates for repeatable triage.
Add native distributed RVS orchestration for multi-instance same-case runs.
Generate operation-specific X-Tension DLL bridges for in-process gaps.
Dynamically register X-Tension-backed tools when X-Ways is open.
Add reporting workflows for timeline, search hit, and tagged-file exports.
References
X-Ways X-Tensions API: https://www.x-ways.net/forensics/x-tensions/api.html
X-Ways manual: https://www.x-ways.net/winhex/manual.pdf
X-Ways scripting: https://www.x-ways.net/winhex/scripting.html
X-Ways command-line setup notes: https://www.x-ways.net/winhex/setup.html
X-Ways release mailing list: https://www.x-ways.net/winhex/mailings/
Available Tools
32 toolsbuild_case_db_path_string_triage_commandB
Build, but do not run, the local X-Ways case-DB path-string triage PowerShell command.
Inputs: search_root, output_root, throttle_limit, max_matches_per_file. Returns: result
build_launch_commandC
Build the X-Ways launch command without executing it.
Inputs: executable (required), case_path, evidence_path, script_path, +2 more. Returns: result
build_path_usage_pattern_triage_commandA
Build, but do not run, the local sanitizer command for XwfPathExport JSONL output.
Inputs: jsonl_path (required), report_directory (required), run_id. Returns: result
cache_xways_manualC
Cache and index the X-Ways manual locally for offline model lookup.
Inputs: source, cache_dir, refresh, download_latest, +2 more. Returns: result
case_run_manifest_templateC
Return a generic forensic case-run manifest template for loose tool-adapter integration.
Inputs: case_id, question, evidence_os, evidence_mode, +2 more. Returns: result
create_workspaceB
Create a case workspace with evidence, export, report, log, and script folders.
Inputs: case_name (required), base_dir. Returns: result
create_xtension_scaffoldC
Generate a local X-Tension bridge scaffold with API provenance notes.
Inputs: name (required), output_root, purpose, api_reference, +3 more. Returns: result
discover_installationsC
Discover X-Ways, WinHex, X-Ways Imager, and XWFIM executables.
Inputs: search_roots, max_depth. Returns: result
environmentA
Return server configuration, platform, and execution safety status.
Inputs: no named parameters. Returns: result
harness_folder_triageC
Run read-only folder triage and write forensic-copilot-compatible artifacts.
Inputs: case_name (required), input_root (required), staging_root, output_root, +5 more. Returns: result
harness_init_caseC
Create a forensic-copilot-compatible manifest, report stub, and audit log.
Inputs: case_name (required), input_roots, staging_root, output_root, +4 more. Returns: result
harness_xwfim_preflightC
Run XWFIM preflight and write artifacts, status JSON, report stub, and audit log.
Inputs: case_name (required), xwfim_root (required), staging_root, output_root, +4 more. Returns: result
hash_fileB
Hash a file using comma-separated algorithms such as md5,sha1,sha256.
Inputs: path (required), algorithms. Returns: result
headless_xways_referenceC
Retrieve local manual snippets relevant to X-Ways command-line and scripting automation.
Inputs: topic, cache_dir, limit. Returns: result
inspect_xwfim_cacheC
Validate XWFIM Temp ZIP downloads, including truncated viewer archives.
Inputs: path. Returns: result
launch_xwaysC
Launch X-Ways only when XWAYS_MCP_ALLOW_EXECUTE=1 and confirm=true.
Inputs: executable (required), case_path, evidence_path, script_path, +4 more. Returns: result
manual_statusC
Report local X-Ways manual candidates and the offline manual index status.
Inputs: search_roots, cache_dir, check_online, timeout. Returns: result
plan_parallel_xways_jobsC
Plan manual-backed parallel X-Ways workers without launching them.
Inputs: case_name (required), evidence_paths (required), workspace_root, case_path, +11 more. Returns: result
plan_xways_operationC
Choose the preferred X-Ways route: headless, native distributed RVS, X-Tension, then UI.
Inputs: operation (required), known_headless, known_xtension_api, requires_in_process, +1 more. Returns: result
public_xways_releaseC
Fetch the public X-Ways release version from X-Ways web pages.
Inputs: timeout. Returns: result
redaction_statusC
Report whether a local file appears to contain common case-sensitive patterns.
Inputs: path (required). Returns: result
redact_local_fileC
Redact a local file to another local file without passing case text through MCP.
Inputs: input_path (required), output_path, alias_map_path, include_alias_map. Returns: result
run_case_db_path_string_triageC
Run local case-DB path-string triage only when XWAYS_MCP_ALLOW_CASE_READ=1 and confirm=true.
Inputs: search_root, output_root, throttle_limit, max_matches_per_file, +2 more. Returns: result
run_path_usage_pattern_triageC
Run local X-Tension JSONL usage-pattern sanitizer only when case-read gate is enabled.
Inputs: jsonl_path (required), report_directory (required), run_id, confirm, +1 more. Returns: result
search_xways_manualC
Search the local X-Ways manual/docs index for command syntax and workflow details.
Inputs: query (required), cache_dir, limit, max_chars. Returns: result
testenv_buildC
Create a disposable fixture environment and immediately run harness checks.
Inputs: name, evidence_os, root, cache, +1 more. Returns: result
testenv_createC
Create a synthetic disposable fixture environment for windows/linux/macos/generic evidence.
Inputs: name, evidence_os, root, cache, +1 more. Returns: result
testenv_destroyB
Delete a managed disposable fixture environment only when confirm=true.
Inputs: name, evidence_os, root, confirm, +1 more. Returns: result
testenv_listC
List managed disposable fixture environments.
Inputs: root. Returns: result
testenv_runC
Run harness checks against an existing disposable fixture environment.
Inputs: name, evidence_os, root. Returns: result
triage_inventoryC
Create a read-only filesystem triage inventory for a folder or mounted evidence tree.
Inputs: root (required), max_files, hash_small_files. Returns: result
validate_archiveC
Validate a ZIP archive and report truncation or bad entries.
Inputs: path (required). Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 32 tools
Each tool serves a distinct purpose, such as building commands, running triage, managing test environments, or accessing the manual. No two tools have ambiguous or overlapping functionality.
Tool names follow snake_case and mostly adhere to a verb_noun pattern (e.g., build_, run_, create_). Minor inconsistencies exist, such as 'harness_folder_triage' versus 'harness_init_case' and 'triage_inventory' using a noun_verb structure.
With 32 tools, the server is on the higher end of the typical range. While each tool has a clear role, the count feels heavy for a focused forensic tool adapter, though not excessive.
The tool set covers essential tasks like launching X-Ways, building commands, running triage, and managing test environments. However, gaps remain in direct evidence analysis and case database interaction beyond path-string triage.
Related MCP Connectors
Remote MCP for Android CLI agent build gate, structured receipts, audit logs, and reviewer-ready evi
Audit, pin and diff agent tool lists; preflight and watch remote MCP servers. Free tier; x402.
Run and manage H Company's Computer-Use Agents from any MCP client.
MCP tools for agents: web research, content extraction, email, DNS, and blockchain intelligence.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceExposes Sysinternals and NirSoft Windows diagnostic binaries as MCP tools with safe subprocess execution. Dynamically registers tools from a binaries directory with built-in security filters for destructive operations.-
- FlicenseNot gradedqualityDmaintenanceEnables digital forensics investigation by exposing SANS SIFT tools (The Sleuth Kit, Volatility 3, Plaso, etc.) as callable MCP tools, running in a self-contained Docker container with safe, allowlisted commands.-
- AlicenseNot gradedqualityBmaintenanceEnables autonomous digital forensics and incident response by wrapping SIFT Workstation tools as MCP tools and orchestrating a multi-agent AI pipeline for evidence analysis and remediation planning.2MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to inspect Autopsy forensic cases through read-only MCP tools for case metadata, filesystem and artifact search, timeline and account queries, evidence extraction, and hash-chained audit/seal verification.1 npm2GPL 3.0