
Research
/Security News
Malicious Chrome and Firefox Extensions Steal Crypto Traders’ Session and Wallet Data
Malicious Chrome and Firefox extensions target Axiom Trade and Padre users, stealing session tokens and wallet data.
@bolyra/mcp
Advanced tools
Bolyra ZKP authentication middleware for Model Context Protocol (MCP) servers — adds mutual zero-knowledge proof of human-delegated agent identity to any MCP server, over stdio or HTTP.
Drop-in middleware that adds mutual zero-knowledge proof authentication to any Model Context Protocol server. One wrapper call, no changes to your tool handlers. Works over stdio and HTTP.
Dev mode uses mock proofs — no circuit artifacts, no trusted setup, instant startup. Use it to build and test your server before wiring real ZKP verification.
npm install @bolyra/mcp @bolyra/sdk @modelcontextprotocol/sdk
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
import { withBolyraAuthStdio } from '@bolyra/mcp';
import { createDevIdentities, attachBolyraProof } from '@bolyra/sdk';
import { z } from 'zod';
// Server
const server = new McpServer({ name: 'my-server', version: '1.0.0' });
server.registerTool(
'read_file',
{ description: 'Read a file', inputSchema: z.object({ path: z.string() }) },
async ({ path }) => ({ content: [{ type: 'text', text: 'file contents...' }] }),
);
withBolyraAuthStdio(server, {
devMode: true,
toolPolicy: { read_file: 0b01n, write_file: 0b11n },
});
await server.connect(new StdioServerTransport());
Client side:
import { createDevIdentities, attachBolyraProof } from '@bolyra/sdk';
const { human, agent } = await createDevIdentities();
const auth = await attachBolyraProof(human, agent, { devMode: true });
// stdio
await client.callTool({ name: 'read_file', arguments: { path: '/tmp/x' }, _meta: auth.meta });
// HTTP
await fetch('/mcp', { headers: { ...auth.headers }, ... });
Every tools/call request must carry a proof bundle: a pair of Groth16 proofs (one from the human's circuit, one from the agent's) bound to a shared session nonce.
The server side:
params._meta.bolyra (stdio) or the Authorization: Bolyra <base64> header (HTTP).BolyraAuthContext to the request for downstream handlers.Discovery calls (initialize, tools/list) pass through unauthenticated.
Delegation chains (v=2 bundles) narrow scope from root credential to leaf agent across multiple hops. The effective bitmask seen by tool policies is always the leaf's — the most-restricted scope.
withBolyraAuthStdio(server: McpServer, config: BolyraMcpConfig): void
Wraps an McpServer instance. Must be called before server.connect(transport).
bolyraAuthMiddleware(config: BolyraMcpHttpConfig): express.RequestHandler
Express middleware. Mount before your MCP HTTP handler. Rejects unauthenticated tools/call requests with HTTP 401.
attachBolyraProof(
human: HumanIdentity,
agent: AgentCredential,
options?: AttachProofOptions,
): Promise<BolyraClientAuth>
Runs a handshake and returns { headers, meta, bundle }. Pass options.devMode = true to skip real proving and emit a mock bundle.
attachDelegatedBolyraProof(
human: HumanIdentity,
rootCred: AgentCredential,
hops: DelegationHopSpec[],
options?: AttachProofOptions,
): Promise<BolyraClientAuth>
Like attachBolyraProof but walks a delegation chain and returns a v=2 bundle.
verifyBundle(bundle: BolyraProofBundle, config: BolyraMcpConfig): Promise<BolyraAuthContext>
Verify a bundle directly — useful for custom transports or offline verification.
checkToolPolicy(
toolName: string,
ctx: BolyraAuthContext,
policy: ToolPermissionPolicy,
): { allowed: boolean; reason?: string }
Check a BolyraAuthContext against a tool's required bitmask.
createDevIdentities(options?: DevIdentityOptions): Promise<DevIdentities>
Returns fixed-seed { human, agent, operatorKey } — deterministic, no circuit artifacts required. Logs a warning on first call. Never use in production.
Swap devMode: true for a real resolveCredential resolver and point the SDK at your circuit artifacts:
withBolyraAuthStdio(server, {
resolveCredential: async (commitment) => myRegistry.get(commitment),
toolPolicy: { read_file: 0b01n, write_file: 0b11n },
sdkConfig: {
circuitDir: '/path/to/circuits/build',
rpcUrl: 'https://sepolia.base.org',
registryAddress: '0x2781dF8b6381462d881C833Fb703d68c661c9577',
},
});
Full config interface:
interface BolyraMcpConfig {
network?: string; // DID network label (default: 'base-sepolia')
minScore?: number; // Minimum score floor 0–100 (default: 70)
maxProofAge?: number; // Nonce freshness window in seconds (default: 300)
toolPolicy?: ToolPermissionPolicy;
devMode?: boolean; // Mock verification — dev/test only
resolveCredential?: (commitment: string) => Promise<AgentCredential | null>;
sdkConfig?: BolyraConfig;
}
The HTTP variant adds authScheme?: string (default "Bolyra").
| Transport | Bundle location | Notes |
|---|---|---|
| stdio (Claude Desktop, Cursor, Cline) | params._meta.bolyra | MCP spec defines no stdio auth surface; _meta is the only protocol-level field |
| HTTP / SSE / Streamable-HTTP | Authorization: Bolyra <base64-bundle> | Custom auth scheme per RFC 7235; aligns with OAuth 2.1 resource-server pattern |
Both produce the same BolyraAuthContext on the server side. Tool handlers don't need to know which transport was used.
See examples/protected-file-server/ for a complete stdio server + client pair using dev mode. Run it with:
cd integrations/mcp
npm run example:protected-file-server
FAQs
Gate MCP tool calls so only authorized agents can call sensitive tools — Bolyra ZKP authentication middleware for Model Context Protocol servers, over stdio or HTTP.
The npm package @bolyra/mcp receives a total of 74 weekly downloads. As such, @bolyra/mcp popularity was classified as not popular.
We found that @bolyra/mcp demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Research
/Security News
Malicious Chrome and Firefox extensions target Axiom Trade and Padre users, stealing session tokens and wallet data.

Security News
GPT-6 Astra hits 100% on ExploitBench and finds zero-days autonomously, while independent tests reveal scope violations and monitoring gaps.

Product
Socket can now send alerts and supply chain attack notifications to Microsoft Teams, with filters that route the right updates to each channel.