|
1 | | -# VOUCH PROTOCOL |
| 1 | +# Vouch Protocol |
2 | 2 |
|
3 | 3 | [](https://discord.gg/RXuKJDfC) |
| 4 | +[](https://github.com/vouch-protocol/vouch/blob/main/LICENSE) |
| 5 | +[](https://github.com/vouch-protocol/vouch) |
4 | 6 |
|
5 | | -[](https://www.gnu.org/licenses/agpl-3.0) |
6 | | - |
7 | | -```text |
8 | | -
|
9 | | -__ __ ____ _ _ _____ _ _ |
10 | | -\ \ / / / __ \ | | | | / ____| | | | | |
11 | | - \ \ / / | | | || | | | | | | |__| | |
12 | | - \ \/ / | |__| || |__| | | |____ | __ | |
13 | | - \__/ \____/ \____/ \_____| |_| |_| |
14 | | -
|
15 | | -``` |
16 | | - |
17 | | -    |
18 | | - |
19 | | -> ⚠️ **v0.1 Alpha Notice:** This is an experimental protocol designed to spark discussion around AI Identity. It is **not yet audited** for production use. Contributions and security critiques are highly welcome. |
| 7 | + __ __ ____ _ _ _____ _ _ |
| 8 | + \ \ / / / __ \ | | | | / ____| | | | | |
| 9 | + \ \ / / | | | || | | | | | | |__| | |
| 10 | + \ \/ / | |__| || |__| | | |____ | __ | |
| 11 | + \__/ \____/ \____/ \_____| |_| |_| |
20 | 12 |
|
21 | 13 | > **"The 'Green Lock' for the Agentic Web."** |
22 | 14 |
|
23 | 15 | **Vouch** is the open-source standard for **AI Agent Identity, Reputation, & Liability**. It provides the missing cryptographic handshake to allow autonomous agents to prove their intent and accountability. |
24 | 16 |
|
25 | | ---- |
26 | | - |
27 | | -## 1. The Premise |
28 | | -The web was built for humans using browsers. The new web is being browsed by AI Agents. Currently, these agents are treated as second-class citizens—blocked by firewalls because they cannot prove their intent. |
29 | | - |
30 | | -* **Existing ID:** Relies on User Identity ("Who are you?"). |
31 | | -* **Agent ID:** Requires Intent Identity ("What are you doing, and who is accountable?"). |
32 | | - |
33 | | -**Vouch is the protocol that allows an AI Agent to prove its legitimacy to a server without human intervention.** |
34 | | - |
35 | | ---- |
36 | | - |
37 | | -## 2. The Philosophy |
38 | | -1. **Identity must be machine-readable:** Verification must happen in milliseconds via HTTP headers, not CAPTCHAs. |
39 | | -2. **Reputation is the new Firewall:** We move from "Block all bots" to "Trust verified agents." |
40 | | -3. **Liability is the Anchor:** An agent must carry a cryptographic signature that links its actions back to a legal entity. |
41 | | - |
42 | | ---- |
43 | | - |
44 | | -## 3. The Technical Standard |
45 | | -Vouch binds a **Reputation Key** to an **Agent Instance** via the `did:web` standard. |
46 | | - |
47 | | -| Component | Description | |
48 | | -| :--- | :--- | |
49 | | -| **The Passport** | A `vouch.json` file hosted on the agent's domain containing public keys. | |
50 | | -| **The Handshake** | A cryptographic proof sent via the `Vouch-Token` header. | |
51 | | -| **The Score** | A dynamic Reputation Score signed by the issuer. | |
| 17 | +> **⚠️ Public Beta:** This protocol is v1.0 compliant but the implementation is currently in **Beta**. Please report issues on GitHub. |
52 | 18 |
|
53 | 19 | --- |
54 | 20 |
|
55 | 21 | ## ⚡ Quick Start |
56 | 22 |
|
57 | 23 | ### 1. Installation |
58 | | -```bash |
59 | | -pip install -r requirements.txt |
60 | | -``` |
61 | | - |
62 | | -### 2. The Standard (`vouch.json`) |
63 | | -Host this file at `https://your-domain.com/.well-known/vouch.json`. |
64 | 24 |
|
65 | | -```json |
66 | | -{ |
67 | | - "id": "did:web:finance-bot.example.com", |
68 | | - "verificationMethod": [{ |
69 | | - "type": "JsonWebKey2020", |
70 | | - "publicKeyJwk": { "kty": "OKP", "crv": "Ed25519", "x": "..." } |
71 | | - }] |
72 | | -} |
73 | | -``` |
| 25 | + pip install vouch-protocol |
74 | 26 |
|
75 | | -### 3. Usage (Python SDK) |
| 27 | +### 2. Usage |
76 | 28 |
|
77 | 29 | **For Gatekeepers (Verifying an incoming agent):** |
78 | 30 |
|
79 | | -```python |
80 | | -from fastapi import FastAPI, Header, HTTPException |
81 | | -from vouch import Verifier |
| 31 | + from fastapi import FastAPI, Header, HTTPException |
| 32 | + from vouch import Verifier |
82 | 33 |
|
83 | | -app = FastAPI() |
84 | | -verifier = Verifier(trusted_key_json) |
| 34 | + app = FastAPI() |
85 | 35 |
|
86 | | -@app.post("/api/resource") |
87 | | -def protected_route(vouch_token: str = Header(alias="Vouch-Token")): |
88 | | - # 1. Verify the Cryptographic Signature |
89 | | - is_valid, passport = verifier.check_vouch(vouch_token) |
90 | | - |
91 | | - if not is_valid: |
92 | | - raise HTTPException(status_code=401, detail="Untrusted Agent") |
| 36 | + @app.post("/api/resource") |
| 37 | + def protected_route(vouch_token: str = Header(alias="Vouch-Token")): |
| 38 | + # Verify the cryptographic intent |
| 39 | + is_valid, passport = Verifier.verify(vouch_token) |
93 | 40 | |
94 | | - # 2. Check Reputation & Liability |
95 | | - agent_id = passport['sub'] |
96 | | - score = passport['vc'].get('reputation_score', 0) |
97 | | - |
98 | | - return { |
99 | | - "status": "Welcome", |
100 | | - "agent": agent_id, |
101 | | - "trust_score": score |
102 | | - } |
103 | | -``` |
| 41 | + if not is_valid: |
| 42 | + raise HTTPException(status_code=401, detail="Untrusted Agent") |
| 43 | + |
| 44 | + return {"status": "Verified", "agent": passport.sub} |
104 | 45 |
|
105 | 46 | --- |
106 | 47 |
|
107 | | -## 4. Architecture & Roadmap |
108 | | - |
109 | | -* **Phase 1 (Current):** Client-side Python SDK (MIT License) to drive adoption among agent builders (LangChain, AutoGen). |
110 | | -* **Phase 2:** Server-side Gatekeeper Middleware (Nginx/Cloudflare) to enforce verification. |
111 | | -* **Phase 3:** The Vouch Registry (Federated Reputation History). |
| 48 | +## �� Integrations |
112 | 49 |
|
113 | | -## 🤝 Contributing |
114 | | -We are looking for adapters for LangChain and CrewAI. |
| 50 | +### 1. Model Context Protocol (MCP) |
| 51 | +Vouch includes a native MCP server for Claude Desktop & Cursor. |
115 | 52 |
|
116 | | -Run the Red Team security suite locally: |
117 | | -```bash |
118 | | -python tests/red_team.py |
119 | | -``` |
120 | | - |
121 | | -**License:** MIT |
122 | | - |
123 | | -## 📜 License |
124 | | -This project is licensed under the **GNU Affero General Public License v3.0 (AGPLv3)**. |
125 | | -* **Open Source:** Free to use, modify, and distribute. |
126 | | -* **Network Use:** If you run Vouch as a service (SaaS), you must share your modifications. |
127 | | -* **Commercial:** Contact us for commercial licensing options. |
128 | | - |
129 | | -## 🔌 Integrations |
130 | | - |
131 | | -### 1. Model Context Protocol (MCP) for Claude & Cursor |
132 | | -Vouch includes a native MCP server. This allows AI Assistants (like Claude Desktop) to cryptographically sign sensitive actions before executing them. |
133 | | - |
134 | | -**Configuration for `claude_desktop_config.json`:** |
| 53 | +**Configuration:** |
135 | 54 |
|
136 | 55 | { |
137 | 56 | "mcpServers": { |
138 | 57 | "vouch": { |
139 | 58 | "command": "python3", |
140 | 59 | "args": ["-m", "vouch.integrations.mcp.server"], |
141 | 60 | "env": { |
142 | | - "VOUCH_PRIVATE_KEY": "YOUR_PRIVATE_KEY", |
| 61 | + "VOUCH_PRIVATE_KEY": "YOUR_KEY", |
143 | 62 | "VOUCH_DID": "did:web:your-domain.com" |
144 | 63 | } |
145 | 64 | } |
146 | 65 | } |
147 | 66 | } |
148 | 67 |
|
149 | | -### 2. LangChain Adapter |
150 | | - |
151 | | - from vouch.integrations.langchain.tool import VouchSignerTool |
152 | | - tools = [VouchSignerTool()] |
153 | | - |
154 | | -### 3. AutoGPT Command |
155 | | -Vouch automatically registers the `sign_with_vouch` command when installed in the AutoGPT plugins folder. |
156 | | - |
157 | | -## 🛡️ Defensive Disclosure (Prior Art) |
158 | | -**Publication Date:** December 14, 2025 |
159 | | -**Subject:** Cryptographic Binding of AI Agent Intent via Model Context Protocol (MCP) |
160 | | - |
161 | | -To ensure the freedom of the ecosystem to build secure agents, we explicitly disclose the following novel method as Prior Art: |
162 | | - |
163 | | -**1. The "Identity Sidecar" Pattern** |
164 | | -This protocol describes a method where an MCP Server acts as a local "Identity Proxy" for a stateless Large Language Model (LLM). Unlike traditional architectures where keys are embedded in the application code, this method isolates the cryptographic keys within the MCP interface layer. |
165 | | - |
166 | | -**2. Just-in-Time (JIT) Intent Signing** |
167 | | -The system implements a workflow where the LLM must request a "Vouch-Token" for a specific action *before* execution. The MCP server acts as an Auditor, reviewing the `integrity_hash` of the proposed tool call. If valid, it signs the intent with a `did:web` identity. |
168 | | - |
169 | | -**3. Non-Repudiation of Tool Execution** |
170 | | -This generates a cryptographically verifiable audit trail that binds three distinct entities: |
171 | | -1. The **Identity** (The DID holding the key). |
172 | | -2. The **Intent** (The specific function call and parameters). |
173 | | -3. The **Time** (Nonce-protected timestamp). |
174 | | - |
175 | | -This disclosure is intended to prevent the patenting of "Identity-Aware Tool Execution" mechanisms by third parties. |
176 | | - |
177 | | -### 4. CrewAI Integration |
178 | | -Vouch works as a native Tool in CrewAI agents. |
| 68 | +### 2. LangChain & CrewAI |
| 69 | +Vouch works as a native Tool for most agent frameworks. |
179 | 70 |
|
180 | 71 | from vouch.integrations.crewai.tool import VouchSignerTool |
181 | 72 |
|
182 | | - # Assign the identity tool to your agent |
183 | 73 | agent = Agent( |
184 | | - role='Financial Analyst', |
185 | | - goal='Sign transactions securely', |
186 | | - tools=[VouchSignerTool()], |
187 | | - verbose=True |
| 74 | + role='Analyst', |
| 75 | + tools=[VouchSignerTool()] |
188 | 76 | ) |
189 | 77 |
|
190 | | -### 5. Microsoft AutoGen Integration |
191 | | -Use Vouch to sign messages between conversable agents. |
| 78 | +--- |
192 | 79 |
|
193 | | - from vouch.integrations.autogen.tool import VouchSignerTool |
| 80 | +## 📜 License & Legal |
194 | 81 |
|
195 | | - # Register the tool with your AutoGen UserProxy |
196 | | - user_proxy.register_function( |
197 | | - function_map={"sign_intent": VouchSignerTool().run} |
198 | | - ) |
| 82 | +This project is licensed under the **GNU Affero General Public License v3.0 (AGPLv3)**. |
| 83 | +[View Full License](https://github.com/vouch-protocol/vouch/blob/main/LICENSE) |
| 84 | + |
| 85 | +## 🛡️ Defensive Disclosure |
| 86 | +This protocol includes a defensive disclosure (Prior Art) published Dec 14, 2025, to protect the ecosystem from patent trolls. |
| 87 | +[Read Disclosure](https://github.com/vouch-protocol/vouch/blob/main/README.md#%EF%B8%8F-defensive-disclosure-prior-art) |
0 commit comments