{"id":46574886,"url":"https://github.com/usk6666/yorishiro-proxy","last_synced_at":"2026-05-23T11:01:21.274Z","repository":{"id":358172816,"uuid":"1240247529","full_name":"usk6666/yorishiro-proxy","owner":"usk6666","description":"AI-native MITM proxy — MCP server for traffic interception, recording \u0026 replay","archived":false,"fork":false,"pushed_at":"2026-05-23T09:02:07.000Z","size":14691,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-23T09:27:37.312Z","etag":null,"topics":["mcp-server","mitm-proxy","penetration-testing","proxy","security","vulnerability-assessment"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/usk6666.png","metadata":{"files":{"readme":"README-ja.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":"NOTICE","maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-15T23:24:42.000Z","updated_at":"2026-05-23T07:52:38.000Z","dependencies_parsed_at":null,"dependency_job_id":"9184eb1a-b851-4163-bd32-10bc7a98fc6f","html_url":"https://github.com/usk6666/yorishiro-proxy","commit_stats":null,"previous_names":["usk6666/yorishiro-proxy"],"tags_count":50,"template":false,"template_full_name":null,"purl":"pkg:github/usk6666/yorishiro-proxy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usk6666%2Fyorishiro-proxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usk6666%2Fyorishiro-proxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usk6666%2Fyorishiro-proxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usk6666%2Fyorishiro-proxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/usk6666","download_url":"https://codeload.github.com/usk6666/yorishiro-proxy/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usk6666%2Fyorishiro-proxy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33392816,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-23T04:15:53.637Z","status":"ssl_error","status_checked_at":"2026-05-23T04:15:53.242Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["mcp-server","mitm-proxy","penetration-testing","proxy","security","vulnerability-assessment"],"created_at":"2026-03-07T09:23:57.032Z","updated_at":"2026-05-23T11:01:21.259Z","avatar_url":"https://github.com/usk6666.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/images/yorishiro-proxy_banner.png\" alt=\"Yorishiro Proxy\" width=\"600\"\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eAI-First MITM プロキシツール\u003c/strong\u003e\u003cbr\u003e\n  AI エージェントのためのネットワークプロキシ — MCP を通じてトラフィックを傍受・記録・リプレイ\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/usk6666/yorishiro-proxy/actions/workflows/ci.yml\"\u003e\u003cimg src=\"https://github.com/usk6666/yorishiro-proxy/actions/workflows/ci.yml/badge.svg\" alt=\"CI\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://goreportcard.com/report/github.com/usk6666/yorishiro-proxy\"\u003e\u003cimg src=\"https://goreportcard.com/badge/github.com/usk6666/yorishiro-proxy\" alt=\"Go Report Card\"\u003e\u003c/a\u003e\n  \u003ca href=\"LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/badge/License-Apache_2.0-blue.svg\" alt=\"License\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"README.md\"\u003eEnglish\u003c/a\u003e\n\u003c/p\u003e\n\n\u003e **Beta** — yorishiro-proxy は開発中です. APIs, configuration formats, and protocol など、マイナーバージョン間でも変更される可能性があります。Non-HTTP/HTTPS プロトコル (gRPC, WebSocket, Raw TCP, SOCKS5など) も実験的な機能提供段階です。\n\n---\n\nYorishiro Proxy は [MCP (Model Context Protocol)](https://modelcontextprotocol.io/) サーバとして動作し、11 個の MCP ツールを通じて AI エージェントにプロキシ操作の完全な制御を提供します。Claude Code やその他の MCP 対応エージェントと組み合わせることで、手動の UI 操作なしに自動化されたセキュリティテストワークフローを実現します。ビジュアル確認やインタラクティブな操作のための組み込み Web UI も利用できます。\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/images/yorishiro-proxy_webui_flows.png\" alt=\"Web UI - Flows\" width=\"800\"\u003e\n\u003c/p\u003e\n\n## 機能\n\n- **トラフィック傍受・記録** -- 自動 CA 証明書管理付き MITM プロキシ\n- **Resender** -- ヘッダ/ボディ/URL のオーバーライド、JSON パッチ、生 HTTP 編集によるリクエストリプレイ\n- **Fuzzer** -- シーケンシャル/パラレルモードと非同期実行による自動ペイロードインジェクション\n- **Macro** -- 変数抽出とテンプレート置換によるマルチステップリクエストシーケンス\n- **Intercept** -- リクエスト/レスポンスをリアルタイムで保持・検査し、リリース・変更・ドロップ\n- **Auto-Transform** -- マッチするトラフィックへの自動リクエスト/レスポンス変更ルール\n- **Target Scope** -- 到達可能なホストを制限する 2 層セキュリティ境界（Policy + Agent）\n- **マルチプロトコル** -- HTTP/1.x, HTTPS (MITM), HTTP/2 (h2c/h2), gRPC, WebSocket, Raw TCP, SOCKS5\n- **マルチリスナ** -- 異なるポートで複数のプロキシリスナを同時実行\n- **mTLS クライアント証明書** -- ホスト単位のクライアント証明書による相互 TLS 認証\n- **TLS 検証制御** -- ホスト単位の TLS 検証設定とカスタム CA 指定\n- **フロータイミング** -- フェーズ別タイミング記録（DNS、接続、TLS ハンドシェイク、リクエスト、レスポンス）\n- **フローエクスポート/インポート** -- JSONL、HAR 1.2、cURL エクスポート形式\n- **SOCKS5 リスナ** -- proxychains 連携のための SOCKS5 プロキシ（オプションのユーザ名/パスワード認証付き）\n- **上流プロキシ** -- HTTP または SOCKS5 プロキシ経由のチェーン接続\n- **Streamable HTTP MCP** -- Bearer トークン認証によるマルチエージェント共有アクセス\n- **Comparer** -- 2 フロー間の構造化 diff（ステータスコード、ヘッダ、ボディ長、タイミング、JSON キーレベル diff）\n- **AI Safety** -- SafetyFilter の Input Filter が破壊的ペイロード（DROP TABLE、rm -rf 等）をブロック。Output Filter がレスポンス内の PII（クレジットカード番号、メールアドレス、電話番号等）を AI エージェントへの返却前にマスク（生データは Flow Store に保存）。レート制限（グローバル/ホスト別 RPS）と診断バジェット（リクエスト数/時間制限）による 2 層 Policy+Agent アーキテクチャ\n- **プラグインシステム** -- [Starlark](https://github.com/google/starlark-go) スクリプトでプロキシのリクエスト/レスポンスパイプラインを拡張\n- **Web UI** -- ビジュアル確認とインタラクティブテストのための組み込み React/Vite ダッシュボード\n\n## クイックスタート\n\n### 1. バイナリの取得\n\n[GitHub Releases](https://github.com/usk6666/yorishiro-proxy/releases) ページからビルド済みバイナリをダウンロードするか、ソースからビルド:\n\n```bash\ngit clone https://github.com/usk6666/yorishiro-proxy.git\ncd yorishiro-proxy\nmake build    # bin/yorishiro-proxy に出力\n```\n\n### 2. MCP の設定\n\n`install` サブコマンドで MCP 連携を簡単にセットアップできます:\n\n```bash\n# 現在のプロジェクト用に設定（.mcp.json を生成）\nyorishiro-proxy install mcp\n\n# ユーザレベルで設定（~/.claude/settings.json）\nyorishiro-proxy install mcp --user-scope\n```\n\nClaude Code などの MCP クライアントに最適な設定（stdio MCP トランスポート有効、ログ出力をファイルにリダイレクト）が自動生成されます。\n\nCA 証明書は初回実行時に自動生成され、`~/.yorishiro-proxy/ca/` に保存されます。\n\n### 3. サーバの単独起動\n\nサーバを直接起動することもできます。デフォルトではランダムなループバックポートで HTTP MCP サーバが起動し、接続情報が `~/.yorishiro-proxy/server.json` に書き込まれます:\n\n```bash\n# デフォルト設定で起動\nyorishiro-proxy server\n\n# 固定ポートでブラウザ自動オープン\nyorishiro-proxy server -mcp-http-addr 127.0.0.1:3000 -open-browser\n```\n\n起動時にログに Web UI の URL が出力されます:\n\n```\nWebUI available url=http://127.0.0.1:3000/\n```\n\n認証トークンは `~/.yorishiro-proxy/server.json` に書き込まれ、デバッグログレベル（`-log-level debug`）では URL に含まれた形でも出力されます。\n\n### 4. 最初のキャプチャ\n\nMCP サーバが起動したら、AI エージェントからトラフィックキャプチャを開始できます:\n\n```\n1. プロキシを起動        -\u003e proxy_start で listen_addr \"127.0.0.1:8080\"\n2. HTTP_PROXY を設定     -\u003e 対象アプリケーションをプロキシに向ける\n3. CA 証明書をインストール -\u003e query ca_cert で証明書パスを取得\n4. トラフィックを発生     -\u003e query flows でキャプチャされたフローを確認\n5. 検査・リプレイ        -\u003e resend で変更を加えてリプレイ\n```\n\n## MCP ツール\n\nすべてのプロキシ操作は 11 個の MCP ツールとして公開されます:\n\n| ツール | 用途 |\n|--------|------|\n| `proxy_start` | キャプチャスコープ、TLS パススルー、インターセプトルール、Auto-Transform、TCP フォワーディング、プロトコル設定付きでプロキシリスナを起動 |\n| `proxy_stop` | 1 つまたはすべてのリスナのグレースフルシャットダウン |\n| `configure` | ランタイム設定変更（上流プロキシ、キャプチャスコープ、TLS パススルー、インターセプトルール、Auto-Transform、接続制限） |\n| `query` | 統合情報取得: フロー、フロー詳細、メッセージ、プロキシステータス、設定、CA 証明書、インターセプトキュー、マクロ、Fuzz ジョブ/結果 |\n| `resend` | 記録されたリクエストをミューテーション付きでリプレイ（メソッド/URL/ヘッダ/ボディのオーバーライド、JSON パッチ、生バイトパッチ、ドライラン）および 2 フローの構造化比較 |\n| `fuzz` | ペイロードセット、ポジション、並行制御、停止条件付きの Fuzz テストキャンペーンを実行 |\n| `macro` | 変数抽出、ガード、フック付きのマルチステップマクロワークフローを定義・実行 |\n| `intercept` | インターセプトされたリクエストに対してリリース、変更して転送、またはドロップ |\n| `manage` | フローデータの管理（削除/エクスポート/インポート）と CA 証明書の再生成 |\n| `security` | Target Scope ルール、レート制限、診断バジェットの設定（Policy Layer + Agent Layer） |\n| `plugin` | Starlark プラグインの一覧表示、リロード、有効化、無効化をランタイムで実行 |\n\n## Web UI\n\n組み込み Web UI は HTTP MCP アドレスで提供されます（デフォルトで有効）。\n\n| ページ | 説明 |\n|--------|------|\n| **Flows** | プロトコル、メソッド、ステータスコード、URL パターンによるフィルタリング付きフロー一覧 |\n| **Dashboard** | リアルタイムトラフィックサマリー付きフロー統計概要 |\n| **Intercept** | インライン編集付きリアルタイムリクエスト/レスポンスインターセプト |\n| **Resender** | オーバーライド、JSON パッチ、生 HTTP 編集、ドライランプレビュー付きリクエストリプレイ |\n| **Fuzz** | ペイロードセットと結果分析付きの Fuzz キャンペーン作成・管理 |\n| **Macros** | 変数抽出付きマルチステップリクエストワークフロー |\n| **Security** | URL テスト付き Target Scope 設定（Policy + Agent Layer） |\n| **Settings** | プロキシ制御、TLS パススルー、Auto-Transform ルール、CA 管理など |\n\nWeb UI は Streamable HTTP MCP でバックエンドと通信します — AI エージェントと同じプロトコルです。\n\n## 対応プロトコル\n\n| プロトコル | 検出方式 | 備考 |\n|-----------|---------|------|\n| HTTP/1.x | 自動 | フォワードプロキシモード |\n| HTTPS | CONNECT | 動的証明書発行による MITM |\n| HTTP/2 | h2c / ALPN | クリアテキスト・TLS 両対応、ストリーム単位のフロー表示 |\n| gRPC | HTTP/2 content-type | サービス/メソッド抽出、ストリーミング対応、構造化メタデータ表示 |\n| WebSocket | HTTP Upgrade | メッセージ単位の記録・表示 |\n| Raw TCP | フォールバック | 認識されないプロトコルをキャプチャ、TCP フォワーディングマッピング対応 |\n\n## CLI\n\nyorishiro-proxy は以下のサブコマンドを提供します:\n\n| サブコマンド | 説明 |\n|------------|------|\n| `server` | プロキシサーバを起動（サブコマンド省略時のデフォルト） |\n| `client` | 実行中のサーバに対して CLI で MCP ツールを呼び出し |\n| `install` | コンポーネントのインストール・設定（MCP, CA, Playwright） |\n| `upgrade` | GitHub Releases からアップデートを確認・インストール |\n| `version` | バージョン情報を表示 |\n\n`client` サブコマンドは実行中のサーバに接続し、`key=value` パラメータで MCP ツールを呼び出します。スクリプティングやアドホックなペンテストワークフローに便利です:\n\n```bash\nyorishiro-proxy client query resource=status\nyorishiro-proxy client proxy_start listen_addr=127.0.0.1:8080\nyorishiro-proxy client query resource=flows limit=10\n```\n\nサーバフラグ、クライアントオプション、環境変数の全一覧は `yorishiro-proxy server -help` / `yorishiro-proxy client -help` を実行するか、[ドキュメント](https://usk6666.github.io/yorishiro-proxy-docs/)を参照してください。\n\n## アーキテクチャ\n\n```\nLayer 4 TCP リスナ\n  → プロトコル検出 (peek bytes / ALPN)\n    → コネクションスタック (TCP → TLS → HTTP/1 | HTTP/2 → WS | gRPC | gRPC-Web | SSE | Raw)\n      → Pipeline (HostScope → HTTPScope → Safety → PluginPre → Intercept → Transform → PluginPost → Record [→ UpgradeStep])\n        → フロー記録 (L7 Message + L4 Envelope.Raw)\n          → MCP ツール (傍受 / リプレイ / 検索 / Plugin Introspect)\n```\n\n- Layer 4 (TCP) でコネクションを受け取り、コネクションごとに `Layer` スタックを構築\n- 外部プロキシライブラリ不使用 — Go 標準ライブラリベースで構築\n- MCP-first: すべての操作は MCP ツールとして排他的に公開\n- React/Vite で構築された組み込み Web UI を Streamable HTTP 経由で提供\n\n設計の根拠とデータモデルは [RFC-001 Envelope + Layered Connection Model](docs/rfc/envelope.md) を参照してください。\n\n## ドキュメント\n\nドキュメントは **[usk6666.github.io/yorishiro-proxy-docs](https://usk6666.github.io/yorishiro-proxy-docs/)** で公開しています。\n\n## コントリビューション\n\nコントリビューションを歓迎します！変更を加える前に、まず Issue を開いて議論してください。\n\n## ライセンス\n\nApache License, Version 2.0 の下でライセンスされています。全文は [LICENSE](LICENSE) を参照してください。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fusk6666%2Fyorishiro-proxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fusk6666%2Fyorishiro-proxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fusk6666%2Fyorishiro-proxy/lists"}