Skip to content

Local Web Control Center (verity view)

verity view starts a zero-signup, fully local web console for Verity. It runs on a pure Python standard-library HTTP server bound to loopback, serves a zero-build ES module single-page app bundled inside the verity-redteam-core wheel, and exposes every Free capability — workstation audits, project scans, the demo lab, the SQL guard, passport and CVE lookups, SBOM / OWASP / baseline management, and the stream timeline — from one screen.

No account, no cloud upload, no telemetry, no external CDN. All verdicts stay deterministic (0% LLM).


Quick start

# Launch the control center for the current workspace (opens your browser)
verity view

# Index specific report files or directories
verity view ./artifacts ~/.verity/reports

# Run a scan or the demo lab, then open the results in the viewer
verity scan --path . --view
verity test --demo --view

# Zero-install via uv
uvx --from verity-redteam-core verity view

On startup the CLI prints the session URL:

Verity viewer running at http://127.0.0.1:8766/#token=<256-bit-session-token>

Open the URL (it is opened automatically unless --no-open, CI=true, or VERITY_NO_BROWSER=1 is set). The token lives in the URL fragment, so it is never sent over HTTP or in Referer headers; the app moves it to sessionStorage and strips it from the address bar immediately.


Command options

verity view [PATHS ...] [--host HOST] [--port PORT] [--strict-port]
            [--watch | --no-watch] [--read-only] [--strict-auth]
            [--no-open] [--allow-live-scan]
Option Type Default Description
PATHS paths workspace defaults Artifact files or directories to index (.json, .sarif, .jsonl, mcp_stream.log).
--host string 127.0.0.1 Loopback host to bind. Only 127.0.0.1, ::1, or localhost are accepted; anything else exits 2.
--port integer 8766 Bind port. If busy, an OS-assigned free port is used unless --strict-port.
--strict-port flag off Fail instead of falling back when the port is in use.
--watch / --no-watch flag on Poll indexed paths for new or updated artifacts and push them live to the UI.
--read-only flag off Disable every mutating / executing action (403 READ_ONLY_MODE). Browsing reports still works.
--strict-auth flag off Require the session token on all /api/v1/* routes, not only on POST.
--no-open flag off Do not open a browser window.
--allow-live-scan flag off Backward-compatible alias; interactive actions are already enabled on loopback.

The --view flag on verity scan and verity test saves the run, indexes it, and launches the same viewer.

Exit codes

Code Condition
0 Server shut down cleanly (Ctrl+C)
2 Non-loopback --host, or --strict-port with a busy port

Screen layout

The interface follows a "most used on top, progressive depth below" layout.

  • Workspace root, server status (Loopback · Watch ON, Read-Only Mode, Pro badges).
  • ⌘K command palette (native modal <dialog> with light dismiss).
  • Activity drawer mirroring backend activity live.
  • Three-state theme switch (System / Dark / Light), remembered per browser.
  • Copy session URL (for opening a second tab).

Hero quick-launch strip

Always visible, one click each:

  1. Audit Workstation — scans all 17 supported IDE / agent MCP client locations.
  2. Scan Project / Path — path input plus presets: Full, CI Gate ≥ HIGH, Offline, OWASP + SBOM.
  3. Run Demo Lab — runs the four deterministic synthetic targets (sqlite-basic, postgres-sqli, mongo-nosql, code-exec).
  4. Quick SQL / CVE Check — jump straight into the SQL guard or advisory lookup.

A progress bar driven by server-sent scan_progress events appears while work runs.

Posture ribbon

Run selector for every indexed artifact, refresh, drag-and-drop / file picker for external .json, .sarif, and .jsonl reports (read in the browser, no upload), CI gate badge, severity filter pills, and KPI counters (findings, scanned files, OWASP score, suppressed).

The six views

View What you can do
Findings & Reports Sortable findings table (keyboard j / k, / to search), filters, finding inspector (Evidence / Remediation / Raw JSON), one-click baseline suppress / unsuppress, copy # verity-ignore: <RULE>, export JSON / Markdown / HTML / CycloneDX 1.6 / SPDX 2.3 (SARIF [Pro]).
Scan Studio Visual builder for every verity scan option: target paths, config / schema files, 17 client toggles, --scan-global, composable --scanners, --typosquat-threshold, --call-analysis, --reachable-only, --live-probe, --offline, --compliance, --fail-on-severity — with a live equivalent CLI command and GitHub Action YAML to copy.
SQL & Runtime Guards 7-dialect SqlSecurityGuard workbench (postgres, mysql, sqlite, duckdb, tsql, bigquery, snowflake) with presets, params, timeout, projection allowlist, and LIKE sanitizer; demo traps; live URL / stdio probes; UCP rug-pull hash save and diff. Pro guard cards are shown as previews.
Passports & CVEs Offline OSV advisory lookup (package, version, CVE / GHSA, tool, CWE) and MCP server passport matching from tool definitions.
SBOM, Drift & Baseline OWASP MCP Top 10 scorecard, SBOM component explorer with CycloneDX / SPDX download, baseline entry manager, inventory snapshot save and diff.
Stream & MCP Server Backend activity and mcp_stream.log timeline, local verity serve health probe, and copyable client configuration snippets for Claude Desktop, Cursor, VS Code, Windsurf, and Antigravity.

Backend activity log

Noisy access logs (static files, health polling) are silenced. Each meaningful action is recorded once as a concise, sanitized line, kept in a 500-entry ring buffer, and streamed to the UI:

[21:50:18] SCAN      ./src -> 4 findings (1 CRITICAL, 2 HIGH, 1 MEDIUM) (58ms)
[21:50:31] SQL-GUARD postgres -> BLOCKED (2ms)
[21:50:52] DEMO      all -> 4 targets (29ms)
[21:51:05] BASELINE  suppress verity:v1:4c91e2... -> ok

Every field is stripped of ANSI escape and control characters and passed through secret redaction before it is printed, buffered, or streamed.


Security model

Because the console can run scans and edit baselines, every request passes four independent checks before any handler runs:

  1. Loopback-only bind. The server only binds 127.0.0.1, ::1, or localhost.
  2. Literal Host allowlist. Requests whose Host header is not the loopback address and bound port are rejected with 403, defeating DNS-rebinding attacks.
  3. Cross-site gate. Sec-Fetch-Site: cross-site / same-site and foreign Origin headers are rejected with 403.
  4. Session token. A per-launch secrets.token_urlsafe(32) token must be sent as X-Verity-View-Token on every POST (and on every API route with --strict-auth). It is compared in constant time.

Additional hardening:

  • Strict Content Security Policy with no inline script or style: default-src 'none'; script-src 'self'; style-src 'self'; img-src 'self' data:; connect-src 'self'; font-src 'self'; object-src 'none'; base-uri 'none'; frame-ancestors 'none'; form-action 'self'.
  • X-Content-Type-Options: nosniff, Referrer-Policy: no-referrer, X-Frame-Options: DENY.
  • The UI builds DOM nodes with textContent / createElement only — no HTML string sinks.
  • Actions call typed in-process Python APIs; nothing is executed through a shell.
  • All API payloads are secret-scrubbed (API keys, PEM private keys, DSN passwords).
  • --read-only locks all mutations for shared screens or demos.

REST and SSE API

Endpoint Method Purpose
/, /static/* GET Bundled single-page app.
/api/v1/health GET Version, Pro status, read-only / watch flags, artifact count, workspace.
/api/v1/runs GET Indexed artifacts with posture summaries.
/api/v1/runs/<id> GET Run detail with ?offset=&limit= pagination.
/api/v1/runs/<id>/export?fmt= GET json, md, html, cyclonedx, spdx; sarif requires Pro.
/api/v1/activity GET Activity ring buffer.
/api/v1/events GET Server-sent events: activity, scan_progress, artifact_added, artifact_updated, keep-alive pings.
/api/v1/tabs GET Extra view tabs registered by plugins.
/api/v1/actions/scan POST Run a scan in-process and index the report.
/api/v1/actions/test POST Demo targets, live probes, UCP hash diff.
/api/v1/actions/guard-sql POST SQL guard validation, projection, LIKE sanitizing.
/api/v1/actions/lookup POST Advisory lookup and passport matching.
/api/v1/actions/baseline POST Suppress / unsuppress, status, inventory save / diff.
/api/v1/actions/mcp-status GET Local verity serve health and client snippets.
/api/v1/explain POST Pro plugin route; returns PRO_FEATURE_REQUIRED in Free.

Indexed artifact kinds

Kind Detected by
verity.scan.v1 JSON with summary and findings (output of verity scan --format json).
verity.test.v1 JSON with results (output of verity test --format json).
verity.sbom.v1 CycloneDX (bomFormat) or SPDX (spdxVersion) JSON.
sarif.v2.1.0 .sarif or JSON with version: 2.1.0 and runs.
verity.stream.jsonl .jsonl files and mcp_stream.log.

Runs started from the UI are saved under ./artifacts/ when that directory exists, otherwise under .verity/reports/ in the workspace, so they persist across restarts.


Free vs. Pro

  • Live SARIF export and /api/v1/explain return 403 with "error": "PRO_FEATURE_REQUIRED" when verity-pro is not installed. Nothing is written.
  • Viewing an existing .sarif file works in Free, fully offline.
  • Pro plugins extend the viewer through ViewerRegistry (register_artifact_parser, register_api_route, register_tab) discovered from the verity.plugins entry point.

Troubleshooting

Symptom Fix
403 on every action Open the exact URL printed at startup (with #token=), or use Copy Session URL from an authenticated tab.
403 READ_ONLY_MODE Restart without --read-only.
Port 8766 already used The viewer picks a free port automatically; pass --strict-port to fail instead.
Browser does not open CI or VERITY_NO_BROWSER is set, or --no-open was passed; open the printed URL manually.
--host 0.0.0.0 rejected Intentional. The console is loopback-only; use SSH port forwarding for remote access.
New reports not appearing Ensure --watch is on (default) and the file is inside an indexed path, or press Refresh.