MCP gateway for enterprise: central auth, SSO, tool allowlists and audit logs

An MCP gateway is the control point that can provide SSO-backed access, tool allowlists and audit logs for agent traffic, but the MCP spec does not supply it. Managed and open-source gateways document different parts of this, so each control must be checked against the edition or license you choose.

On this page

MCP gateway: does it meet our SSO, allowlist and audit requirement?

Staff agents that connect to many MCP servers leave no single place to see or restrict those connections. An MCP gateway is the component that can supply SSO-backed access, tool allowlists and audit logs for all of them. The MCP specification does not provide these controls itself: it states that MCP cannot enforce its security principles at the protocol level, so they must be built into the applications and infrastructure around it. Managed services and open-source gateways document these controls, but under different editions and licenses, so a control listed for one tier may be absent from the one you plan to run. Protocol-level OAuth rules sit on the authentication page; this section covers what the gateway adds, and you must confirm each control in the edition you intend to deploy.

The gateway also changes token handling. The MCP authorization specification requires an MCP server to accept only tokens issued for its own resources, so the gateway that clients see is the token audience and must validate tokens issued to it. Amazon Bedrock AgentCore documentation advises against token passthrough in production and recommends on-behalf-of token exchange, where the gateway swaps the caller's token for a new audience-scoped token for each downstream target. Azure API Management validates JWTs against Microsoft Entra ID or other identity providers and logs to Azure Monitor, but it exposes MCP tools only, not resources or prompts. The open-source options document different pieces: agentgateway (Apache-2.0) lists JWT, API key and OAuth authentication with CEL-based RBAC, IBM ContextForge (Apache-2.0) offers virtual servers that expose only selected tools with federated SSO, and Microsoft's MCP Gateway (MIT) runs on Kubernetes and checks Entra ID identities and app roles.

Before you choose, write down three answers for each candidate. First, which identity the gateway checks at the front door, and whether it can restrict tools per user or group as well as per server. Second, whether each tool call is logged with the caller's identity, the tool name and the decision, and whether those records reach your SIEM. Third, which of these controls ship in the edition or license you would run. Managed services list controls by product tier, and open-source projects may place admin interfaces, federated SSO or RBAC in separate builds, so confirm each control in writing with the vendor or project and test it in your environment. The gateway also holds credentials for every upstream server, which makes it a high-value target that needs its own hardening and review. DeployOpen can test a gateway configuration for SSO, allowlist and logging gaps as part of an AI agent rollout security review.

Which MCP gateways document SSO, tool allowlists and logs

This table compares six MCP gateways on inbound authentication and SSO, tool-level allowlists and logging, and hosting and license. Each cell starts with a status: built in, paid tier only, needs an outside component, or not documented. Where a capability is not documented, confirm it with the vendor before approval, and confirm which Azure API Management tier includes MCP endpoints and the self-hosted gateway.

GatewayInbound auth and SSOTool allowlists and logsHosting and license
Amazon Bedrock AgentCore GatewayBuilt in: accepts JWTs from any OAuth identity provider, plus IAM callers. Token exchange is recommended over passthrough.Built in: a Cedar policy engine checks every tool call and logs decisions to CloudWatch.Managed AWS service, not open source. Confirm pricing and terms with AWS.
Azure API Management MCP endpointsBuilt in: JWT validation against Microsoft Entra ID or other identity providers.Built in: rate limits, IP filtering and Azure Monitor logging. Per-tool allowlists not documented.Managed Azure service with a self-hosted gateway. Confirm with Microsoft which tier includes MCP endpoints and the self-hosted gateway.
agentgatewayBuilt in: JWT, API key and OAuth authentication. SSO provider setup not documented; confirm.Built in: fine-grained RBAC with a CEL policy engine, rate limits, OpenTelemetry logs and traces.Open source under Apache-2.0. Runs standalone or on Kubernetes.
IBM ContextForgeBuilt in: federated SSO with Google, GitHub or Entra ID. A Keycloak SSO test profile is provided.Built in: virtual servers expose only selected tools, with RBAC in Helm deployments. Audit log not documented.Open source under Apache-2.0. Self-hostable, with an Admin UI and air-gapped deployment support.
Microsoft MCP GatewayBuilt in: callers authenticate with Microsoft Entra ID. Other identity providers not documented.Built in: access by resource creator, required app roles and mcp.admin. Per-tool allowlists and logs not documented.Open source under MIT. Reverse proxy and control plane for MCP servers on Kubernetes.
Docker MCP GatewayOAuth flows supported. Central SSO for callers not documented; confirm with Docker.Built in: each catalog server runs in its own container, with logging and call tracing. Per-tool allowlists not documented.Open source under MIT. Secrets handled through Docker Desktop secrets management.

Where the gateway sits in the MCP authorization model

The gateway is the token audience, so it has to validate tokens for itself. The MCP authorization specification, revision 2026-07-28, says an MCP server must accept only tokens valid for its own resources and must not accept or transit any other tokens. When clients address the gateway as their MCP server, the gateway is the resource those tokens name. Its JWT validation therefore has to check the aud claim against the gateway's own identifier, along with issuer, signature and expiry. Ask the team deploying the gateway to demonstrate two tests: a token issued for a different audience is refused at the gateway, and a token with the correct audience is accepted. A gateway that only confirms the token is signed by the corporate identity provider can pass a routine login test while still accepting tokens issued for other services.

The gateway should make an on-behalf-of token exchange for each upstream target and send each upstream only a token issued for that target. Amazon Bedrock AgentCore Gateway guidance on outbound authorization says token passthrough is not the recommended approach for production and recommends on-behalf-of exchange, in which the gateway swaps the caller's token for a new audience-scoped token for each downstream target. This matters because an upstream that receives the caller's own token can accept a credential it was never issued for, and a single token then carries access across several services. With exchange, each upstream sees a token scoped to itself. In a quote or design review, ask the vendor whether exchange happens per target, whether the scopes and lifetime of exchanged tokens are configurable, and which identity provider issues them.

Enforcement happens at three points: authentication at the gateway, a policy check on each tool call, and a log entry for each decision. The products express the policy differently. AgentCore Gateway can attach a Cedar policy engine that checks every tool call and logs decisions to CloudWatch. agentgateway applies fine-grained RBAC with a CEL policy engine and emits OpenTelemetry logs and traces. IBM's ContextForge uses virtual servers that expose only selected tools, so a team can publish a narrower tool set to each group without changing the upstream server. The MCP specification states that the protocol cannot enforce its own security principles, so the gateway and the applications around it must carry that job. Before approval, send a denied tool call through each candidate gateway and confirm the log entry records the caller identity, the tool name and the decision.

How a tool call moves from SSO to the upstream server and the log

The flow starts when an agent client signs in through the corporate identity provider and receives an access token. Each tool call then reaches the MCP gateway, which first checks that the token was issued for the gateway itself. It next checks the requested tool against the allowlist. Allowed calls pass through a token exchange that issues a new token scoped to the upstream MCP server, and the gateway writes an audit event after the result returns. Calls with an invalid token or a tool outside the allowlist take the denied path: the gateway rejects the call and still sends the denial to the SIEM or cloud monitoring service. Check that every denial records the caller identity and the tool name.

Allowed and denied tool calls both produce an audit event in the log destination.

Choosing the identity provider, policy model and deployment

Each card is one decision that changes what the gateway costs to run, how much control your administrators keep, and how much review your security team must do. The choices interact: the identity provider sets the token audience, the deployment model decides who operates the gateway and its policy engine, and the log destination determines what your SIEM receives.

Identity provider and token validation

Choose the identity provider that issues the tokens your gateway accepts. Microsoft Entra ID is documented for ContextForge and Microsoft's MCP Gateway, and Azure API Management validates JWTs from Entra ID or other providers. Keycloak appears in ContextForge only as a test profile, so do not run production sign-in on it without your own review. The gateway must validate tokens issued for its own audience. Ask who pays for IdP licensing and claim mapping work, and who owns role changes.

MCP authorization spec

Managed or self-hosted gateway

Amazon Bedrock AgentCore Gateway is a managed AWS service, and Azure API Management also offers a self-hosted gateway. The open-source options run in your own environment: agentgateway and ContextForge are Apache-2.0 licensed, while Microsoft's MCP Gateway and Docker's MCP Gateway are MIT licensed. A managed gateway moves patching and scaling to the vendor but adds a vendor-metered data path to document. A self-hosted gateway keeps traffic in your network, and your team then owns upgrades, backups and policy testing. Ask each vendor for current pricing and metering terms.

AgentCore overview

Policy model: allowlists, RBAC and Cedar

Each product models access differently, so the policy you review is tied to one engine. ContextForge exposes only the tools a virtual server lists, agentgateway evaluates fine-grained RBAC rules written with a CEL policy engine, and AgentCore can attach a Cedar policy engine that checks every tool call. Microsoft's MCP Gateway maps read and write access to Entra app roles and the resource creator. Policies written for one engine do not carry over to another, so budget review time for the language you choose.

AgentCore policy docs

Token handling: exchange or passthrough

Decide whether the gateway forwards the caller's token or exchanges it for a new one. The MCP authorization spec says a server must not accept or pass along tokens issued for other resources, so passthrough breaks that rule at the gateway. AgentCore's documentation says passthrough is not the recommended approach for production and recommends on-behalf-of exchange, where the gateway issues a new audience-scoped token for each downstream target. Exchange adds an identity flow to test for every downstream target, so scope your review by target count.

AgentCore outbound auth

Log destination and SIEM export

Choose where gateway decisions land before the first agent connects. AgentCore logs policy decisions to CloudWatch, Azure API Management sends logs to Azure Monitor, and agentgateway emits OpenTelemetry logs and traces that a compatible collector can receive. Docker's MCP Gateway includes logging and call tracing. Reaching your SIEM usually means running an exporter or collector, so confirm each product's export format and retention setting. Confirm who pays for ingestion and storage, because tool-call logs grow with agent activity.

Network boundary and air-gapped support

Decide where the gateway runs relative to your upstream MCP servers and your clients. agentgateway runs standalone or on Kubernetes, Microsoft's MCP Gateway is a reverse proxy for Kubernetes, and ContextForge documents air-gapped deployment. A managed gateway runs in the vendor's cloud, so confirm the network path to private upstream servers and where traffic travels. Verify air-gapped support in your own build before relying on it, because documentation alone does not prove an offline install works. Cluster operations fall to your platform team.

agentgateway repository

How the answer changes by identity provider and hosting

If your staff sign in with Microsoft Entra ID, the key question is which Microsoft-built control plane you run and whether it validates tokens issued for its own audience. Azure API Management can expose REST APIs or existing MCP servers as governed MCP endpoints, validating JWTs against Entra ID or other identity providers, with rate limits, IP filtering and Azure Monitor logging. Review the overview of MCP servers in Azure API Management for the exact scope.

  • Azure API Management scope: It supports MCP tools but not MCP resources or prompts, so confirm that the surfaces you need are the ones it governs.
  • Microsoft MCP Gateway access: Running on Kubernetes, it authenticates callers with Entra ID. Read access goes to the resource creator and holders of the required app roles or mcp.admin, and write access is limited to the creator or mcp.admin holders.
  • ContextForge federated SSO: It supports Entra ID alongside Google and GitHub, with RBAC in Helm deployments. Confirm whether its Entra ID path is the supported production option for your tenant.
  • App role governance: Review who holds mcp.admin, because that role can change access for any server behind the gateway.

Before approval, confirm with Microsoft and each gateway maintainer which token types and app role claims each production component accepts, and whether any self-hosted component needs connectivity back to Azure for policy or logging.

What MCP gateways do not cover for this requirement

A gateway governs only the traffic that passes through it and the records it writes. The gaps below sit outside that control point, in client configuration, tool design, product coverage, log handling, licensing and the content agents read, so each one needs a named owner and a control before approval.

Clients that bypass the gateway

A gateway sees only the traffic routed through it. Clients can still connect straight to upstream MCP servers, and local stdio servers run as processes on the laptop with no gateway log at all. The usual cover is egress rules that let agent hosts reach only the gateway address, combined with managed client configuration that stops staff from adding servers. Check that both controls apply to every approved agent, including desktop and terminal clients.

Permitted tools still cause harm

An allowlisted tool can still delete a record, send a message or change a setting when an agent calls it with the wrong arguments. An allowlist alone does not limit this. The usual cover pairs it with approval rules for write and destructive tools, and with scope design: narrow OAuth scopes, read-only access where the task allows it, and virtual servers that expose only the tools a team needs. Test each approved tool with the arguments an agent would send.

Resources and prompts outside Azure API Management

Azure API Management can govern MCP tools, but it does not cover MCP resources or prompts. If Azure API Management is your gateway, resources and prompts can reach clients by another path unless you block them. The usual cover is a documented decision for each server: block resource and prompt methods at the gateway or in client configuration, or assign them a separate control with its own review. Confirm this behavior with the vendor against the version you deploy.

Azure API Management MCP docs

Log retention and redaction

A gateway records its own decisions, such as which caller invoked which tool and whether policy allowed it. It does not set how long those records are kept, mask personal data or secrets inside tool arguments, or limit who can read them. The usual cover is a written retention schedule, a redaction step before logs leave the gateway, read access restricted to security staff, and forwarding to your existing SIEM. Ask the vendor which fields are logged and whether they can be excluded.

Open-source licenses without support

agentgateway and IBM ContextForge are licensed under Apache-2.0, and Microsoft MCP Gateway and Docker MCP Gateway are licensed under MIT. These licenses grant use rights, but they include no support, security patching or indemnity. The usual cover is a support contract from a vendor or implementation partner, a named internal owner for upgrades, and a pinned version tested before each update. Ask legal whether the license terms meet your procurement requirements.

agentgateway repository

Prompt injection in content agents read

A gateway inspects the tool call, not the content the agent read before making it. A web page, ticket or document can carry instructions that steer the agent into a call that is allowed by policy but unwanted, and the gateway records that call as permitted. The usual cover combines limits on which tools may run after untrusted content is read, user confirmation for those calls, and injection tests against the full agent setup. Assess the client's own injection defenses separately from the gateway.

Order of work to put gateway controls in production

The sequence below moves an MCP gateway from test setup to a controlled production path. Each step ends with a check that a security reviewer can repeat, so the approval record shows which controls were tested and which were not. The order matters because later controls depend on the identity and routing choices made earlier.

  1. Inventory the MCP servers and clients

    Record every MCP client that will reach the gateway, including coding agents, desktop assistants and internal applications, and every upstream MCP server each one calls today. For each server, note whether it is vendor-built, community-maintained or internal, the transport it uses, the data it can read and the actions it can take. Owners sign off on the list. Done means each server has one named owner, one documented purpose and no client path that bypasses the list.

  2. Choose the gateway and identity provider

    The platform team selects the gateway and the corporate identity provider together, because the gateway validates tokens that the identity provider issues. Confirm the exact edition or license tier for each candidate, since SSO, RBAC, policy and audit features are documented for specific editions in the vendor materials. Managed options and self-hosted options carry different hosting and data-flow questions, so record where the gateway runs. Done means a written decision names the gateway, edition, identity provider and hosting location, and the vendor confirms each feature in writing.

  3. Set the token audience and verify rejection

    The gateway is the audience for tokens that clients send to it, so under the MCP authorization spec it must accept only tokens issued for its own resource. Configure it to validate issuer, audience and expiry. Confirm that upstream calls use a separate token for each upstream server, obtained through token exchange, and that the caller's token is never forwarded. Send a token issued for another resource and an expired token, then confirm both are rejected. Capture an upstream request and check that no caller token appears in it. Done means both rejection tests return denials, the capture shows no passthrough, and the results are filed.

  4. Define tool allowlists by role

    Write allowlists that name the tools each role may call on each server, and deny everything not listed. Start with read-only tools for general roles, and treat write, delete and administrative tools as separate grants that need a named approver. Test one out-of-list call per role and confirm the gateway itself denies it, and that the denial appears in the gateway log with the caller identity and tool name. Done means every role has a written list, each test denial is logged, and no client can reach a tool through a name the list does not contain.

  5. Route clients through the gateway

    Point every approved client at the gateway endpoint and remove client configurations that connect straight to upstream servers. On the network side, allow the upstream servers to accept traffic only from the gateway, so a client that ignores its configuration cannot reach them. Test from a client machine that a direct connection to an upstream server fails and that a normal request through the gateway succeeds. Done means client configuration inventories show gateway endpoints only, and network tests confirm the direct path is closed from every client segment in scope.

  6. Send gateway logs to the SIEM

    Forward gateway logs for authentication results, token rejections, allowlist decisions and tool calls to the security information and event management platform. Confirm which fields are recorded, including caller identity, client, server, tool name and decision, and confirm which fields are redacted so that tool arguments and credentials stay out of the log store. Check the retention period configured on the gateway and on the SIEM, ask the vendor where each is set, and align both with your policy. Done means a test call appears in the SIEM with the expected fields, a planted secret in a test argument is redacted, and the retention settings are written down.

  7. Retest prompt injection, token reuse and bypass

    Run the attack cases against the configuration that will go live. Prompt injection cases place instructions inside tool results that try to call tools outside the allowlist. Token reuse cases replay a token issued for another resource or an expired token. Bypass cases try alternate tool names, direct upstream addresses and unlisted roles. Each case should end in a denial that is logged. Done means every case has a recorded result, each failure has a fix and a retest, and the reviewer signs off on the record before approval.

What a security reviewer asks to see for gateway controls

This table lists the evidence a security reviewer typically requests to confirm that an MCP gateway enforces central authentication, tool allowlists and logging. Each row names what the item proves and where it comes from, either in the gateway product or in the organization's own identity provider, network and log systems. Treat a missing item as a gap to close before approval, and confirm each gateway feature against the edition being deployed.

Evidence itemWhat it provesWhere it comes from
Token audience validation test resultsGateway rejects tokens not issued for its own audienceInbound auth test results, plus JWT issuer and audience settings in the gateway
Exported tool allowlist or policy fileWhich tools each identity or virtual server may call, and that unlisted tools are blockedGateway admin export or policy repository; confirm the file format with the vendor
Decision logs for allowed and denied callsEach tool call recorded with caller, tool, decision and timestamp, so denials can be tracedGateway log sink and the organization's SIEM; confirm supported exporters in vendor docs
Upstream credential exchange configurationGateway requests a new audience-scoped token for each upstream serverOutbound auth settings in the gateway and token exchange client setup in the identity provider
Proof that caller tokens are not forwardedUpstream servers receive no token issued to the agent or userCaptured upstream request headers from a test call, plus gateway proxy logs
SSO and identity-group mappingWhich identity provider groups map to gateway roles, and who may change policyIdP application settings, gateway RBAC mapping, and a test sign-in for each group
Gateway version and license recordExact build in use, its license terms, and which features the deployed edition includesRelease tag or image digest, the repository license file, and vendor terms for paid editions
Network egress rules blocking direct upstream accessAgent hosts cannot reach upstream MCP servers except through the gatewayFirewall, security group or network policy exports, plus a failed direct connection test

Questions buyers ask before approving an MCP gateway

What does an MCP gateway cost to run in an enterprise?

The cost has four parts, and the gateway product is only one of them. A managed gateway bills usage under the vendor's own terms, so ask for the written price sheet and the metered units it counts. Your identity provider charges for the users and applications it covers, upstream MCP servers may carry their own licenses or API fees, and your staff time covers design, integration and review. Setup is one-time work: identity configuration, policy design, log wiring and testing. Operation recurs: usage fees, policy changes, upgrades and log storage. A self-hosted open-source gateway has no license fee, but hosting, patching and support are your costs. Ask any vendor or partner for a written quote that separates each of these lines.

How long does an MCP gateway rollout take, and what drives it?

No duration applies across all setups, so ask for a timeline in the written scope. The main drivers are the number of MCP servers the gateway must front, since each one needs its own upstream authentication, tool allowlist and tests. Identity integration is the next driver, including app registrations, group mapping and token audience settings in your identity provider. The log pipeline is the third, because audit records must reach your SIEM or telemetry stack with retention rules agreed in advance. A pilot with two or three servers and one identity provider involves far less work than a rollout across many servers and business units. DeployOpen engagements are fixed-scope, so scope, deliverables and timeline are agreed in writing before work starts.

Can our own team run an MCP gateway without an outside partner?

Yes, if your team already runs the platform you choose and has the skills to operate it. A self-hosted gateway is a service you run, so the team needs administration skills for that platform, such as Kubernetes if the gateway is deployed there. You also need identity administration for your identity provider's app registrations and token settings, security engineering for policy and allowlists, and log engineering for audit trails. Check whether your staff have these skills for the specific product before you commit. Where a gap exists, DeployOpen can plan, implement, harden, document and support self-hosted open-source platforms in your infrastructure, and ongoing support, upgrades and continuous testing are available as retainers.

Is an open-source MCP gateway license enough for enterprise use?

The license grants use rights, so yes, you can run an open-source gateway in production. It does not provide vendor support, security patching or any warranty. Among the gateways covered here, agentgateway is listed as Apache-2.0 in its repository as of November 2026, IBM ContextForge is Apache-2.0, and both Microsoft's MCP Gateway and Docker's MCP Gateway are MIT. Confirm the license file for the exact version you deploy, and check the terms of any bundled or dependent component. Patch timing, vulnerability tracking and upgrade testing then fall to your organization, or to a support contract you buy separately. Name the person who watches advisories, tests upgrades and approves patches before go-live.

Does the MCP spec's OAuth authorization already cover gateway access control?

No. The spec's authorization rules cover protocol behavior: how a client obtains a token, which resource a token is meant for, and that a server must accept only tokens valid for its own resources and must not pass other tokens through. They do not set central policy, such as which MCP servers a team may use, which tools are allowed or which group sees which server. A gateway that clients treat as their MCP server is itself the token audience, so it must validate tokens issued for it and exchange the caller's token for a new, audience-scoped token for each downstream target. Central policy has to come from the gateway's policy engine, enterprise-managed authorization or client configuration. The spec also states that MCP cannot enforce its security principles at the protocol level, so those controls must be built into your deployment.

Does an MCP gateway stop prompt injection attacks on AI agents?

No. A gateway controls which identities reach which servers and which tools they may call, and it can log those calls. It does not judge whether instructions reaching the model are malicious. An injected instruction arriving through a web page, a ticket or a file can still lead an agent to make calls the policy permits, so an allowed read tool may still expose data to the model. Treat the gateway as one control among several: least-privilege scopes on each upstream server, approval steps for write and delete tools, tool allowlists that exclude high-risk tools, and monitoring for unusual call patterns. DeployOpen's AI agent security review tests prompt injection, tool and file permissions, data exposure and credential handling in your setup, then delivers a findings report with fixes and a retest.

How DeployOpen helps you roll out an MCP gateway safely

DeployOpen plans, implements and tests self-hosted MCP gateways inside your own infrastructure, so your security and compliance teams can review the gateway, its SSO configuration, tool allowlists and audit logs directly. Most engagements are fixed-scope and agreed in writing before work starts, and they end with documentation, a findings report with fixes and a retest. Security testing covers the gateway, the upstream tools behind it and the paths agents use to reach them.

How we scope

  • Engagements are fixed-scope, with the gateway, upstream servers and clients named in writing before work starts.
  • We confirm which identity provider issues tokens to the gateway and which SSO settings the scope covers.
  • Tool allowlists, audit log destinations and admin settings are listed as scope items, so reviewers see what is in and out.

How we build

  • We deploy the gateway selected in scope inside your own cloud accounts, data centers or air-gapped networks.
  • We configure SSO and token checks so the gateway accepts only tokens issued for its own audience.
  • We set tool allowlists and policy rules, then test that blocked tools cannot be called through the gateway.

How we hand over

  • You receive written configuration documentation for the gateway, including SSO settings, upstream server list and tool allowlists.
  • Findings from security testing come with fixes, and a retest confirms each fix works in your environment.
  • Your security and compliance teams get the admin, logging and access evidence they need to review the gateway.

How we support

  • Ongoing support, upgrades and continuous testing are available as retainers for the gateway and its allowlists.
  • Continuous testing can recheck the gateway after upstream MCP servers add or change tools.
  • Ask any retainer quote to name which upstream servers, tool allowlists and SSO settings it covers.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.