Sign inSign up

britive/mcp-gateway

By britive

Updated about 20 hours ago

Image
Networking
Security
Monitoring & observability
1

2.1K

britive/mcp-gateway repository overview

Britive MCP Gateway

Governed access to MCP servers. The gateway sits between your MCP clients and the MCP servers they use, shows each person only the tools their access policy allows, injects short-lived credentials into every call so backends never store any, and audits what was used, by whom, and when. Built to integrate with the Britive platform for access lifecycle and policy.

What it does

  • Filters tools per person. The tool list a client sees is the list that user is entitled to. The same check runs again when a tool is called, so a tool that was never listed cannot be invoked by naming it.
  • Injects credentials, never stores them. Access is checked out per call and passed to the backend in headers. Backends stay stateless and hold no long-lived secrets.
  • Audits every call. Who called which tool, on which backend, when, and whether it was allowed — forwarded to your Britive tenant's audit stream.
  • Asks before it delegates. Any MCP client that connects must be explicitly authorized by the signing-in user before it can act as them.
  • Supports replicated deployments. Shared PostgreSQL sessions and database leader election coordinate replicas behind your HTTPS load balancer.
  • Provides optional observability. Enable OpenTelemetry traces, Prometheus latency metrics and bounded MCP progress streaming through gateway settings.

Two kinds of backend

  • Credential injection — the gateway checks out temporary credentials from Britive for that user and that tool, and attaches them to the call.
  • Delegated OAuth — the user authorizes the backend service once; the gateway attaches that authorization on their behalf from then on. Tools on these backends can still be bound to a Britive profile — one that grants admin rights, say — and the gateway checks it out before the call so the access exists while the tool runs. Nothing is injected: the backend authenticates as the user, and the checkout is recorded in your audit stream.

Backends are defined in the Britive platform and picked up without restarting the gateway.

Clients

Anything that speaks MCP over HTTP, including Claude Code, Codex, and MCP Inspector. Claude Desktop connects through a small local relay, since hosted connectors cannot reach a gateway inside your network.

Running it

Three settings: your tenant, a gateway pool token from the Britive console, and a Postgres URL. The database is yours — backups, HA, and encryption stay in your control plane.

docker run -d \
  -e TENANT=acme.prod \
  -e GATEWAY_POOL_TOKEN=... \
  -e DATABASE_URL=postgresql://gateway:[email protected]:5432/gateway \
  britive/mcp-gateway:v1.2.0

Run several behind a load balancer against one shared Postgres — they accept each other's sessions with nothing to configure, because the key that signs them is derived from one the platform mints per gateway pool. Serve it over HTTPS: OAuth tokens cross that connection.

Documentation

Full documentation is coming to learn.britive.com.

Tag summary

Content type

Image

Digest

sha256:06cd021a8

Size

98.3 MB

Last updated

about 20 hours ago

docker pull britive/mcp-gateway