AuditHub MCP Serverのロゴ

AuditHub MCP Server

組織
Veridise

Connect AI agents to AuditHub’s blockchain security tools. Launch scans, review findings, monitor tasks. Open source, Apache 2.0.

公開者Veridise
リポジトリaudithub-mcp
言語Python
フォーク
0
スター
22
利用可能なツール
0
通信方式stdio
カテゴリ
ライセンスApache-2.0
リンク
  • ツールをAIワークフローに接続

    AuditHub MCP Serverは、対応するAIクライアントやAIエージェントから利用できるMCP機能を提供します。

  • 0個の利用可能なツール

    呼び出し可能なアクションを以下で確認できます。サーバーから提供されている場合は、名前や説明も表示されます。

  • コピーして使える設定

    セットアップ用の設定例を使って、お好みのMCPクライアントにこのサーバーを設定できます。

  • オープンソースの注目度

    リンク先のリポジトリには22件のスターと0件のフォークがあります。

AuditHub MCP Server

This repository contains the source code of audithub-mcp, an MCP server for AuditHub.

audithub-mcp allows LLM-based agents to access functionality such as:

  • Discovering information about AuditHub organizations and projects
  • Launching and monitoring AuditHub tool tasks
  • Accessing AuditHub issues and findings

By design, the MCP server limits the functionality to be read-only and non-destructive. Additional features can be enabled through the configuration file.

Warning: LLMs can make mistakes. Verify all tool outputs manually before acting on them.

Prerequisites

  • Python 3.12+
  • uv

The package bundles PAQL as an Emscripten WebAssembly module. Its cross-platform Node.js runtime is installed automatically as a Python dependency, so validate_paql does not require a system PAQL or Node.js installation.

Installation

audithub-mcp is implemented as a Python package, but it is not yet available in PyPI. You must install it directly from this repository.

Global Installation

If you are using the uv package manager, you can install audithub-mcp using uv:

uv tool install 'git+https://github.com/Veridise/audithub-mcp'
audithub-mcp --help

Local Clone

From the repo root:

bash
uv venv
uv sync --active

If your virtual environment is already active and you just want to run the server entrypoint, use:

bash
uv run audithub-mcp --help

Using audithub-mcp

To use audithub-mcp, you need to configure two parts: your agent and the audithub-mcp config file. Once both are configured, the agent should automatically start the MCP server and use its tools.

Agent Configuration

To enable audithub-mcp in your agent, you must add it to the MCP server config for your agent.

The following examples assume that audithub-mcp is available on PATH, and that your config file is located at ~/.config/audithub-mcp/config.yaml.

  • Codex CLI
    • For interactive setup, use codex mcp add audithub-mcp
    • If you want to set it up with a config file, add the following to your .codex/config.toml:
      toml
      [mcp_servers.audithub-mcp]
      command = "audithub-mcp"
      args = ["--config", "~/.config/audithub-mcp/config.yaml"]
  • Claude Code
    • For interactive setup, use claude mcp add audithub-mcp audithub-mcp
    • If you want to set it up with a config file, add the following to your .claude/mcp.json:
      json
      {
        "mcpServers": {
          "audithub-mcp": {
            "command": "audithub-mcp",
            "args": [
              "--config",
              "~/.config/audithub-mcp/config.yaml"
            ]
          }
        }
      }

MCP Server Configuration

You will need to create a YAML file containing the audithub-mcp server creation and ensure that the agent configuration calls audithub-mcp with the --config <path> argument.

If you are not sure where to put the config file, a good default location is in ~/.config/audithub-mcp/config.yaml. The file permissions should be set to 400 (owner read-only) since it contains credentials.

See the config docs for details on how to create the configuration file.

Available MCP Tools

ToolDescription
get_organizationsList allowlisted organizations; pass details=true for full organization records and filter_id to narrow results
get_defi_vanguard_detectorsList all DeFi Vanguard detectors for an organization using the Vanguard listing block format
get_projectsList allowlisted projects in an organization; pass details=true for full project records and filter_id to narrow results
get_versionsList versions for a project; pass details=true for full version records, filter_id to narrow results, and latest_only=true for the latest version only
get_task_infoGet status and details for an AuditHub task
get_task_artifactsList sanitized artifact metadata for an AuditHub task
get_task_artifactFetch a task artifact by ID as base64-encoded content
get_task_logsGet logs for one or more steps of a task and write each result to a local output file
get_task_findingsFetch findings for a task and write them to a local output file
wait_for_task_completionPoll a task until no pending steps remain or the timeout is reached, then return the latest task snapshot and completion state; with no timeout, task-capable clients can invoke it as a task
parse_findings_from_task_logParse one or more task log files into JSON containing findings plus counts written to a local absolute output path
validate_paqlParse a PAQL pattern or Luau query definition with the bundled WebAssembly PAQL validator; optionally typecheck it against the configured dialect
get_version_commentsGet comments for a specific project version
get_version_comment_threadsGet comment threads for a specific project version
get_thread_commentsGet comments for a specific thread within a project version
get_project_issuesGet all issues for a project
get_project_issueGet a specific issue from a project
get_project_commentsGet all comments for a project across all versions
help_contextGet a prompt/instructions on how agents should use the mcp server
run_orca_taskStart an OrCa task for a project version; registered only when task runs are explicitly enabled
run_defi_vanguard_taskStart a DeFi Vanguard task for a project version; registered only when task runs are explicitly enabled
create_version_from_fileCreate a project version by uploading a local .zip archive; registered only when version creation is explicitly enabled
create_version_from_urlCreate a project version from a git repository or archive URL; registered only when version creation is explicitly enabled

All tools return typed Python objects backed by audithub-sdk models.

The optional authenticated POST /shutdown operational route is deliberately not an MCP tool and never appears in tool discovery. It is enabled only for local HTTP mode when --shutdown-secret-file PATH is supplied; see the configuration guide.

The objects returned by get_organizations, get_projects, and get_versions only exposes items belonging to organizations/projects on the configured allowlists.

Available MCP Resources

ResourceDescription
docs://vanguard/custom-detectorsVanguard custom-detector documentation resource; the server fetches the linked markdown files on first access, caches the rendered text in memory, and returns the markdown bodies

Security Model

  • Read-only by default. Default tools are named get_* and only invoke generated audithub-sdk GET endpoints.
  • Task completion polling. wait_for_task_completion repeatedly fetches task details until no pending steps remain or the timeout is reached, then returns the latest sanitized Task snapshot with a boolean completion flag. When called with no timeout by a task-capable client, it can run as a task instead of blocking the request.
  • Opt-in OrCa task execution. The run_orca_task mutation tool is registered only when AH_ENABLE_TASK_RUNS=1 or --enable-task-runs is supplied. It calls the generated OrCa POST endpoint through audithub-sdk.
  • Opt-in DeFi Vanguard task execution. The run_defi_vanguard_task mutation tool is registered under the same task-run opt-in gate. Its inputs are flattened at the top level: organization_id, project_id, version_id, detector selections, and the runtime options. Pass detector selections as two-item JSON arrays [type, id], where builtin selectors use a built-in detector code from get_defi_vanguard_detectors, and custom selectors use the catalog id shown by the same tool. The server resolves those selections through the backend detector catalog before calling the generated DeFi Vanguard v2 POST endpoint.
  • On-chain OrCa mode. When launching OrCa against already deployed contracts, pass deployment_info_file as a path ending in .deployment.json. The server normalizes that into on_chain=True and rejects mismatched paths early so callers do not accidentally launch a local Foundry-style run.
  • Opt-in version creation. The create_version_from_url mutation tool is registered only when AH_ENABLE_VERSION_CREATION=1 or --enable-version-creation is supplied. It calls the generated project version URL POST endpoint through audithub-sdk.
  • Local findings parsing. The parse_findings_from_task_log utility tool reads one or more local task log files, extracts findings with the shared log parser, and writes a JSON file containing the parsed findings plus the total finding count and per-log counts. It does not call the AuditHub API.
  • Local PAQL validation. The validate_paql utility tool runs the bundled PAQL WebAssembly module with the uv-installed Node.js runtime, invokes it directly without a shell, and does not contact AuditHub. Syntax validation is available by default. Typechecking uses the bundled Vanguard Solidity dialect spec; explicitly configured PAQL_NODE_EXECUTABLE, PAQL_WASM_MODULE, and PAQL_DIALECT_SPEC values override the bundled defaults.
  • Detector catalog cache. The DeFi Vanguard v2 built-in detector list is fetched lazily from the AuditHub configuration endpoint and cached in-process for one day. Custom detectors are fetched live on each request from both the organization library and the standard library.
  • Detector listing format. get_defi_vanguard_detectors returns one block per detector. Each block starts with detector: <json> where <json> is a JSON value matching DefiVanguardV2DetectorSelectionInput, followed by title:. Standard-library custom detectors also include description: loaded from the detector payload. Each block ends with ------.
  • Credential isolation. OIDC credentials are read from the environment once at startup and passed into audithub_sdk_ext.AuthenticatedApiClient. They are never accepted as tool arguments and are not surfaced in tool outputs or sanitized error messages.
  • ID allowlisting. The server refuses to access any organization or project whose numeric ID was not explicitly included in AH_ALLOWED_ORG_IDS / AH_ALLOWED_PROJECT_IDS. The check runs before any network request.
  • SDK-only transport. All AuditHub interaction flows through audithub-sdk and audithub_sdk_ext; there is no raw HTTP helper in the MCP server.

Development Workflow

  • Run tests: uv run pytest
  • Type check: uv run mypy
  • Lint: uv run ruff check
  • Format code: uv run ruff format

Override audithub-sdk Locally

To test audithub-mcp against a local checkout of audithub-sdk, add a path source override in the root pyproject.toml, then re-sync the environment.

Example root pyproject.toml override:

toml
[tool.uv.sources]
audithub-sdk = { path = "/absolute/path/to/audithub-sdk", editable = true }

Then run:

bash
uv sync --active

To return to the pinned version, remove the audithub-sdk entry from [tool.uv.sources] and run uv sync --active again.

License

Apache 2.0

インストール

TypingMind
{
  "mcpServers": {
    "audithub-mcp": {
      "command": "audithub-mcp",
      "args": [
        "--config",
        "{{config.CONFIG_PATH}}"
      ],
      "env": {
        "CONFIG_PATH": "<CONFIG_PATH>"
      }
    }
  }
}

AuditHub MCP ServerのMCPを複数のAIモデルで活用

TypingMindはワークスペース単位でMCPツールに接続します。そのため、一度AuditHub MCP Serverに接続すれば、モデルごとに個別に設定することなく、TypingMind内のさまざまなAIモデルで利用できます。 このMCPは、デバイス上のTypingMind MCPコネクタを通じてローカルで動作します。

ローカルコネクタのセットアップガイド

MCPサーバーが、お使いのコンピューター上のローカルファイル、アプリ、非公開リソースにアクセスする必要がある場合は、この方法を使います。

1

MCP設定を開く

TypingMindで「設定」、「詳細設定」、「MCP」の順に進み、「コネクタを設定」を選択してください。

  1. ブラウザでTypingMindを開いてください。
  2. 設定アイコンをクリックしてください。
  3. 「詳細設定」に移動してください。
  4. 「MCP」セクションを開いてください。
  5. 「コネクタを設定」をクリックし、「このデバイス」を選択してください。
「このデバイス」が選択されたTypingMindのMCPコネクタ設定画面
2

コネクタのコマンドを実行

「このデバイス」を選択し、TypingMindからコマンドをコピーしてターミナルで実行してください。MCPの使用中は、プロセスを実行したままにしてください。

  1. TypingMindに表示されるセットアップコマンドをコピーしてください。
  2. macOSではターミナルを、WindowsではWindows Terminalを開いてください。
  3. コマンドを貼り付けて実行してください。
  4. ターミナルで続行の確認を求められた場合は、パッケージのインストールを承認してください。
  5. MCPツールの使用中は、ターミナルウィンドウを開いたまま、プロセスの実行を継続してください。
3

AuditHub MCP Serverをサーバーとして追加

コネクタのステータスが「準備完了」になったら、「サーバーを編集」をクリックし、MCPサーバーの設定を貼り付けてください。

  1. コネクタのステータスが「準備完了」になるまでお待ちください。
  2. 「サーバーを編集」をクリックしてください。
  3. AuditHub MCP ServerのMCPサーバー設定を貼り付けてください。
  4. サーバー一覧を保存してください。
  5. コネクタが引き続き使用可能か確認するには、更新してください。
稼働中のサーバーと「サーバーを編集」ボタンが表示されたTypingMindのMCP設定画面
{
  "mcpServers": {
    "audithub-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

複数のモデルで同じ接続を使用

サーバー一覧を保存し、「プラグイン」を開いてAuditHub MCP ServerのMCPツールを有効にしてください。その後、TypingMindで対応するAIモデルを選択し、チャットでツールを使うか、AIエージェントに割り当ててください。

  1. TypingMindの「プラグイン」ページを開いてください。
  2. AuditHub MCP ServerのMCPツールを有効にしてください。
  3. チャットを開始し、使用するAIモデルを選択してください。
  4. MCPツールをチャットで使うか、AIエージェントに割り当ててください。
  5. MCPに再接続することなく、必要に応じて別のAIモデルに切り替えられます。
選択したAIモデルと有効なMCPツールを使用したTypingMindのチャット
AuditHub MCP Serverを使ってこのタスクを手伝ってもらえますか?
AuditHub MCP Server
はい、読みました。
AuditHub MCP Serverで調べた結果をお伝えします。

よくある質問

AuditHub MCP Server MCPサーバーは何に使いますか?

AuditHub MCP Serverは、対応するAIクライアントを外部ツールやコンテキストに接続するためのMCPサーバーです。TypingMindでは、このMCPサーバーを一度追加するだけで、AIワークスペース内でそのツールを利用できるようになります。

TypingMindでAuditHub MCP Server MCPを複数のAIモデルと併用できますか?

はい。TypingMindはワークスペース単位でMCPツールに接続するため、モデルごとにMCPサーバーを設定する必要はありません。Claude、ChatGPT、Geminiや、TypingMindで設定したその他のAIモデルでAuditHub MCP Serverを利用できます。

TypingMindでAuditHub MCP Server MCPを使うメリットは何ですか?

TypingMindは、複数のAIモデル、プロンプト、プラグイン、AIエージェント、APIキー、MCPツールを1つのワークスペースにまとめられる、LLMチャット向けの優れたフロントエンドです。AuditHub MCP Serverを接続すると、TypingMindでチャットのワークフローを整理しながら、お好みのモデルでそのMCPツールを利用できます。

AuditHub MCP Server MCPをTypingMindに接続するにはどうすればよいですか?

AuditHub MCP ServerはTypingMindのローカルMCPコネクタ経由で動作します。MCPサーバーがコンピューター上のローカルファイル、デスクトップアプリ、コマンドラインツール、プライベートリソースにアクセスする必要がある場合に最適です。

TypingMindでAuditHub MCP Server MCPのどのようなツールを利用できますか?

AuditHub MCP ServerはMCP機能を提供しています。TypingMindのプラグインページで有効にすると、チャットで使用したり、AIエージェントに割り当てたりできます。

AuditHub MCP Server MCPを使うには、APIキーをTypingMindと共有する必要がありますか?

いいえ。TypingMindはローカルファーストの設計で、モデルプロバイダー、APIキー、プロンプト、MCP設定をご自身で管理できます。AuditHub MCP Serverで認証が必要な場合は、接続の作成時に、そのMCPサーバーに必要なヘッダー、OAuth設定、またはローカル設定を追加してください。

関連するMCPサーバー

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇