Hive Zk Attestation

io.github.srotzin由 GitHub 账号 srotzin 发布v1.0.0更新于 Nov 2, 2026

Zero-knowledge attestation for agent capability and trust score claims

已验证Streamable HTTP可网页运行金融开发者工具安全与监控

概览

AI 生成的概览

让助手生成并验证代理状态哈希与 DID 的零知识证明,并把证明承诺锚定到 Base 链上。

可以做什么
  • 生成与验证证明:为代理状态哈希加 DID 生成零知识证明,并用已知验证密钥校验提交的证明。
  • 锚定与查询承诺:把 32 字节的证明承诺写入 Base,并按 Base 交易哈希取回已锚定的证明。
  • 查看电路:列出支持的电路及验证密钥指纹。
  • 管理收益档案:为代理注册 Hive 归因分润计划、查询其 USDC 余额与打款状态,并查看收益排行榜。
适用场景
当两个代理之间,或代理与审计方之间需要在不暴露内部状态的前提下证明某个事实,并希望在 Base 上留下公开承诺时适用。也适合评估 Hive 归因分润计划。注意后端仍处于 RFC 阶段,付费工具目前会返回后端未就绪的错误。
运行要求
远程 streamable HTTP 端点;未声明任何身份验证、环境变量或请求头。付费工具以 Base 上的 USDC 计价,通过 HTTP 402 支付收取。若要在 Aleo 上验证,需要单独的 Aleo(BLS12-377)账户,因为该密钥与 Base 或 Solana 密钥不互通。
安装前请注意
付费工具消耗 Base 上的真实 USDC(证明 0.05 美元,锚定 0.02 美元加 L1 gas),结算被描述为真实主网而非测试网。锚定会把承诺写入公开链。收益类工具会代表调用方注册并调用上游服务。后端处于 RFC 阶段,付费工具目前返回 503 backend_pending。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Hive Zk Attestation,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Web executable,通过 Streamable HTTP。 远程服务在工作区中配置后即可从网页运行时运行。

交给智能体安装

把这段提示词粘贴到 Claude Code、Codex、Cursor 等智能体,或 SourceWeft 对话中。智能体会读取该服务器的安装指南,先向你展示发布者、端点和登录方式,经你同意后再把它添加到你的客户端。密钥不会写进任何命令。

阅读 https://sourceweft.com/mcp/io.github.srotzin%2Fhive-mcp-zk-attestation/install.md,并按其中说明把这个 MCP 服务器接入我的客户端。修改任何配置之前,先告诉我它的发布者、端点和登录方式,等我确认。不要把 API 密钥写进命令或我会提交的文件;问我密钥应从哪里获取。

查看智能体所依据的安装指南

其他 MCP 客户端

把它添加到你客户端的 mcpServers 配置中。

{
  "mcpServers": {
    "hive-zk-attestation": {
      "type": "http",
      "url": "https://hive-mcp-zk-attestation.onrender.com/mcp"
    }
  }
}

README

hive-mcp-zk-attestation

[srotzin/hive-mcp-zk-attestation MCP server]

Verifiable agent state attestations for the autonomous agent economy. RFC-stage v0.1.1.

A Model Context Protocol shim that lets any autonomous agent emit a zero-knowledge attestation of its internal state hash and DID. The primary verification target is Aleo snarkVM (Varuna over BLS12-377), with native Hive verification next, and Risc0 / Plonky2 referenced as future research targets. Attestation-only. No asset bridging. No custody. No wrapped value.

Brand colour: Hive Civilization gold #C08D23.

What this is

An attestation primitive for autonomous agents. The shim exposes five MCP tools that together let one agent prove to another agent — or to a regulator, counterparty, or auditor — that:

  1. The first agent was in a specific internal state, identified by a 32-byte hash.
  2. The state was held by a specific DID.
  3. A commitment to that proof has been anchored to Base at a known block.
  4. The verification path is reproducible against a public, ecosystem-neutral verifier.

The agent never reveals its state. The verifier never learns more than the boolean result and the public inputs. The audit trail is anchored on a public chain. The verification key is portable to compatible verifiers — primarily Aleo snarkVM via Leo.

Why it exists

Autonomous agents transact, hold state, and make decisions on behalf of users. Existing agent-to-agent protocols — MCP, A2A, ACP — assume the agent is willing to publish what it knows. That assumption breaks the moment two agents need to negotiate without leaking inventory, model weights, prompt history, or counterparty positions.

Zero-knowledge proofs are the standard cryptographic answer. The plumbing has not been wired into the MCP / A2A surface that agent runtimes already speak. This shim is that wiring.

Interop targets

Honest priority order. Every name below is a public, ecosystem-neutral verifier or a research direction. There is no co-branding, no partnership, and no shared roadmap with any of these projects.

  1. Aleo snarkVM (Varuna over BLS12-377) — primary. Aleo's native proof system is Varuna (a Marlin/AHP variant using KZG10 over BLS12-377). On-chain verification happens inside snarkVM via the snark.verify opcode (synthesizer/program/src/logic/instruction/operation/snark_verify.rs), which accepts Varuna proofs and verification keys. The TypeScript SDK @provablehq/sdk exposes VerifyingKey.verify() for client-side checks. Mainnet endpoint: https://api.provable.com/v2.
  2. Native Hive verification — proofs verified server-side at the Hive backend. Not yet rails-live; ships when the v0.1 spec is finalized and /v1/zk/* publishes.
  3. Risc0 — researched, not implemented. Future verification target.
  4. Plonky2 — researched, not implemented. Future verification target.

Architecture

┌─────────────┐    state hash + DID     ┌────────────────────────┐│ Agent (any) │ ─────────────────────▶  │  zk_attest_agent_state │└─────────────┘                         │  (attestation payload) │                                        └─────────────┬──────────┘                                                      │ commitment                                                      ▼                                        ┌────────────────────────┐                                        │  zk_anchor_to_base     │                                        │  commitment → Base L2  │                                        └─────────────┬──────────┘                                                      │ tx_hash                                                      ▼                                        ┌────────────────────────┐                                        │  Base L2 (anchor)      │                                        └─────────────┬──────────┘                                                      │                attestation consumed by               │                downstream verifier                   │                                                      ▼            ┌──────────────────────┬─────────────────────────┐            │  Aleo snarkVM        │  Native Hive backend    │            │  (Varuna/BLS12-377   │  (verification at       │            │  via Leo programs in │   hivemorph; not yet    │            │  hive-leo-circuits   │   rails-live)           │            │  — future repo)      │                         │            └──────────────────────┴─────────────────────────┘

Hive emits the attestation. Base anchors the commitment. Verification happens either (a) inside snarkVM via Leo programs that consume the attestation and call snark.verify against a Varuna verification key, or (b) inside the Hive backend once /v1/zk/* publishes. The Leo programs themselves will live in a separate hive-leo-circuits repository — that repo is future work and is not part of this shim.

Future research (Groth16 / Plonk)

Earlier drafts of this shim referenced Groth16 over BN254 and Plonk as if they were first-class. They are not. Aleo's mainnet verification path is Varuna over BLS12-377, and a generic Groth16/BN254 → BLS12-377 verifier inside snarkVM would be roughly two million constraints — researched, not shipped. Groth16 and Plonk remain in this repo only as research-stage references for hypothetical bring-your-own-verifier integrations.

Known gotchas

The whole point of v0.1.1 is honesty about where the integration actually is. Read this section before integrating.

  • BLS12-377 keypair separation. Aleo accounts are BLS12-377 scalar-field keypairs. They are not interoperable with the Base (W1) or Solana (B1) keys an agent may already hold. An agent that wants to verify attestations on Aleo needs a separate Aleo account.
  • No native Groth16 verification on Aleo today. A Groth16/BN254 proof cannot be verified inside snarkVM without a curve-translation circuit (~2M constraints). That circuit is researched, not implemented, and is not part of this shim.
  • Leo deployment cost. Deploying a Leo program to Aleo mainnet costs roughly 1.5 to 2 ALEO credits per program. The forthcoming hive-leo-circuits repository will carry that cost; this shim does not.
  • Backend is RFC-stage. Every paid tool returns 503 backend_pending until /v1/zk/* publishes. The tool surface, costs, and circuit catalog are stable across the v0.1 RFC.
  • Attestation, not bridge. No value moves between Base and Aleo. The shim emits proofs and commitments; nothing is wrapped, mirrored, or escrowed.

What this is NOT

Stated explicitly so there is no ambiguity:

  • Not a bridge. No value, no token, no wrapped asset crosses any chain. The shim emits proofs and commitments, not balances.
  • Not a custody layer. The shim never holds keys for any chain on behalf of the caller. It does not hold user funds, token balances, or signing authority.
  • Not a regulated activity. Emitting a hash commitment to a public chain is not money transmission, securities issuance, or a regulated payment service.
  • Not a partner integration. Aleo snarkVM, Risc0, and Plonky2 are interoperability targets — public open-source verifiers. There is no co-branding, no joint product, no shared roadmap, no Aleo logo usage, and no "powered by Aleo" claim.
  • Not a product for any specific industry vertical. The primitive is commercial dual-use: any autonomous agent that needs verifiable private state can use it.

Threat model

The shim is designed against three concrete threats:

  1. Agent state confidentiality. An agent must be able to prove a fact about its state without revealing the state. Standard zk-SNARK construction; the shim simply exposes it through the MCP surface.
  2. Counterparty proof-of-honesty. When two agents negotiate, each can demand a proof that the other is in a state consistent with the negotiation, without either side opening its book.
  3. Audit trail without exposure. Compliance-conscious operators can publish proof commitments to Base while keeping the underlying state private. The audit trail is verifiable; the data is not exposed.

The shim does not defend against: a compromised agent forging its own state hash before proving it (garbage in, valid proof of garbage out), or a verifier choosing to trust an unrelated verification key. Both are upstream of this primitive.

Tools

ToolCostStatus
zk_attest_agent_state$0.05 USDC on Base503 backend pending
zk_verify_proofFree503 backend pending
zk_anchor_to_base$0.02 USDC + L1 gas503 backend pending
zk_list_circuitsFree503 backend pending (stable circuit catalog returned inline)
zk_query_attestationFree503 backend pending

The backend at https://hivemorph.onrender.com/v1/zk/* is RFC-stage. Until it ships, every paid tool returns:

json
{  "error": "backend_pending",  "retry_after": 86400,  "message": "zk attestation rails are RFC-stage. Backend endpoints publish when the spec is finalized. Tool surface, costs, and circuit list are stable."}

The MCP shim, tool surface, costs, and circuit catalog are stable across the v0.1 RFC. Calling agents can integrate now and consume attestations the moment the backend is live.

Settlement

Real Base USDC. No mocks, no testnet, no simulated settlement. Recipient (canonical Hive treasury, EVM): 0x15184bf50b3d3f52b60434f8942b7d52f2eb436e. Pricing is denominated in USDC; payment is collected via x402 PaymentRequired (HTTP 402) on the paid tools.

Usage

bash
git clone https://github.com/srotzin/hive-mcp-zk-attestationcd hive-mcp-zk-attestationnpm installnode server.js

Then point any MCP client at http://localhost:3000/mcp. Discovery endpoints:

  • GET /health — health probe
  • GET /.well-known/mcp.json — MCP manifest
  • GET /.well-known/agent.json — A2A AgentCard
  • GET /.well-known/oac.json — Open Agent Card JSON-LD

Example: list circuits

bash
curl -s -X POST http://localhost:3000/mcp \  -H 'Content-Type: application/json' \  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"zk_list_circuits","arguments":{}}}'

While the backend is RFC-stage, this returns the stable circuit catalog inline.

License

MIT. See LICENSE.

Hive Gamification

This MCP server is part of the Hive Civilization gamification surface (10-mechanic capability taxonomy).

Surface tags: gamification.spec.v1 · gamification.surface.public · gamification.signal.read-only · gamification.settlement.real-rails

Real rails on Base L2 (USDC 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913). Read-only signal layer. Brand gold #C08D23.

Hive Civilization Directory

Part of the Hive Civilization — agent-native financial infrastructure.

Brand: #C08D23

来源:README.md,提交 e4022e0

工具

8

zk_attest_agent_state

Produce a zero-knowledge attestation of an agent state hash + DID. Primary verification target is Aleo snarkVM (Varuna over BLS12-377); native Hive verification is next. Attestation-only — emits a proof, not a token; no value crosses chains. Cost: $0.05 USDC on Base. Backend RFC-stage; returns backend_pending until rails land.

输入参数circuitagent_did必填state_hash必填public_inputs

zk_verify_proof

Verify a submitted attestation against a known verification key. Aleo snarkVM (Varuna/BLS12-377) is the primary verification target via the snark.verify opcode. Returns boolean validity plus the verification key fingerprint. Free. Read-only — no settlement, no on-chain write.

输入参数proof必填public_inputsverification_key_id必填

zk_anchor_to_base

Write an attestation commitment (32-byte hash) to Base via the Hive gateway. Anchors the attestation only; does not bridge value or move state to Aleo. Aleo snarkVM consumes the attestation independently via Leo programs (future hive-leo-circuits repo). Cost: $0.02 USDC + L1 gas. Backend RFC-stage; returns backend_pending until rails land.

输入参数agent_did必填proof_commitment必填verification_key_id

zk_list_circuits

Enumerate supported circuits and verification key fingerprints. Primary: Varuna over BLS12-377 (Aleo snarkVM-compatible). Research-stage: Groth16, Plonk. Future: Risc0, Plonky2. Free. Read-only.

无需输入参数。

zk_query_attestation

Fetch a previously-anchored attestation by Base transaction hash. Returns the proof commitment, verification key id, agent DID, and block number. Free. Read-only.

输入参数tx_hash必填

hive_earn_register

Register an agent for the Hive Civilization attribution payout program. Settlement on real Base USDC. 5% kickback on attributed traffic, weekly payout. Calls POST https://hivemorph.onrender.com/v1/earn/register on behalf of the caller. Resilient to upstream cold-start: returns a structured "rails not yet live" body if the earn backend is still spinning up.

输入参数agent_did必填payout_address必填attribution_url必填

hive_earn_me

Look up the caller agent's registered earn profile, lifetime + pending USDC balance, last payout tx hash, and next-payout ETA. Real Base USDC, no mock data. Calls GET https://hivemorph.onrender.com/v1/earn/me?agent_did=<did>. Returns "rails not yet live" gracefully if upstream is not yet deployed.

输入参数agent_did必填

hive_earn_leaderboard

Top earning agents on the Hive Civilization, by attribution payout in USDC. Real Base USDC settlement. Calls GET https://hivemorph.onrender.com/v1/earn/leaderboard?window=<window>. Returns "rails not yet live" gracefully if upstream is not yet deployed.

输入参数window

版本历史

1
  1. v1.0.0最新Sep 16, 2026

评分

已满足适用检查项的 100%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通必需25 分
  • 已声明认证方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分