Repository navigation
v0.7.0 (experimental)
The exfiltration attack now runs against GitHub's real MCP server, and Cedar policies can decide who may use which tools.
Upgrading
- No config changes are needed.
gateway.cedaronly applies when you set it, and its engine (@cedar-policy/cedar-wasm) is an optional dependency you install yourself.
@adtl/gateway
- Cedar authorization (#11):
gateway.cedar: { policies, entities?, timeZone? }. Each call becomes a Cedar request (User::"<id>",Action::"tools/call",Tool::"<server>.<tool>") withserver,principalId,listing,timeandargumentsin the context, for rules such as working hours or "only repos in your org". Policies that don't parse stop startup; evaluation errors deny. Tool arguments can't name Cedar entities. - The gateway takes several authorizers (
authorizer: [a, b]); every one must allow, and the first denial is reported. Withrolesandcedarboth set, both apply. CedarAuthorizerandgatewayAuthorizers()are exported.
Examples
examples/github-real-demo(#27): the GitHub-issue exfiltration attack againstgithub-mcp-server(tested with v2.0.3), with two throwaway repos and a fine-grained token. Run 2's labels come from thegithubpreset viaadtl-gateway init, not a hand-written config. Opt-in withnpm run demo:github; not part ofnpm test. It checks for the leak through the GitHub API and deletes the leaked comment afterwards.