By NHI Mgmt Group Editorial TeamPublished 2026-06-08Domain: Agentic AI & NHIsSource: Lasso Security

TL;DR: AI gateways now route enterprise model access, but they do not inspect prompt content, response content, or tool calls, leaving organisations blind to prompt injection, jailbreaks, and sensitive data leakage, according to Lasso Security. The practical shift is that AI traffic inspection is becoming an identity and policy control, not just an observability add-on.


At a glance

What this is: This is an analysis of AI gateway traffic inspection and the key finding is that routing controls alone do not reveal what prompts, responses, and tool calls actually contain.

Why it matters: It matters because IAM and security teams now need to govern AI interactions as a policy-bearing identity surface across NHI, autonomous, and human workflows.

👉 Read Lasso Security's analysis of AI gateway traffic inspection for enterprise AI


Context

AI gateway traffic inspection is the missing control layer when enterprises route model traffic through Kong, Portkey, LiteLLM, Envoy, and similar platforms. The gateway can manage routing, load balancing, and keys, but it does not inspect the semantics of prompts, responses, or tool calls, which is where leakage and misuse often emerge.

That creates a governance gap for identity programmes because the traffic itself now carries policy risk. In practice, AI interactions behave like a new identity-bearing channel, where content inspection, policy enforcement, and audit context have to work together instead of treating the gateway as the full control point.


Key questions

Q: How should security teams govern AI gateway traffic that carries prompts and tool calls?

A: Security teams should govern AI gateway traffic as a runtime policy problem, not just a routing problem. Inspect prompts, responses, and tool calls before they reach downstream systems, and make sure the gateway logs enough context to show what was sent, what was returned, which policy applied, and what action followed.

Q: Why are AI gateways not enough to stop prompt injection and data leakage?

A: AI gateways control where traffic goes, but they do not understand what the traffic means. Prompt injection, jailbreaks, and sensitive data leakage happen inside the content layer, so teams need inspection and policy enforcement that can evaluate the interaction itself, not only the network path.

Q: How do security teams know whether AI traffic controls are actually working?

A: They should look for evidence that policy decisions are consistent across prompts, responses, and tool calls, and that every block, mask, or alert can be traced back to a specific interaction. If the team can only report request volume, then it is measuring transport, not control effectiveness.

Q: What is the difference between gateway routing and AI traffic inspection?

A: Gateway routing moves requests between services and models. AI traffic inspection evaluates the content of those requests and responses for policy violations, sensitive data, and adversarial manipulation. The first is an access-path function. The second is a security enforcement function.


Technical breakdown

Why AI gateway routing is not content inspection

AI gateways sit at the transport and orchestration layer. They can route requests, balance load, and centralise API key handling, but they do not natively determine whether a prompt contains injection payloads, whether a response leaks sensitive data, or whether a tool call violates policy. That distinction matters because security outcomes depend on content semantics, not just traffic visibility. In identity terms, the gateway is handling access path control, while the interaction itself remains a separate enforcement surface. Practical implication: treat gateway logs as necessary telemetry, not as proof that AI interactions are safe.

Practical implication: add content-level inspection where prompt and response semantics can be evaluated before policy violations propagate.

Prompt injection, jailbreaks, and tool calls as policy-bearing events

Prompt injection and jailbreaks are not just model behaviour problems. They are governance failures when untrusted instructions can alter model intent, expose context, or drive downstream tool use. Tool calls make this sharper, because the model is no longer only producing text. It is initiating actions that can touch data sources and external systems. That is why the relevant control boundary is not the LLM alone, but the full interaction path from prompt to response to tool invocation. Practical implication: define policy controls around the full transaction, not only around the model endpoint.

Practical implication: classify tool calls as governed actions and apply policy checks before those actions reach connected systems.

Audit trails for AI traffic need decision context

An audit trail for AI interactions is only useful if it records what was sent, what was returned, which policy applied, and what action was taken. Without that context, teams can see volume but not intent, and they cannot reconstruct whether a block, mask, or alert was justified. This becomes more important as organisations move to multi-model and multi-agent environments, where the same request can traverse several components. Practical implication: design logging for forensic reconstruction and policy accountability, not just for throughput monitoring.

Practical implication: retain request, response, policy, and action metadata together so investigations can reconstruct the full decision path.


Read our 52 NHI Breaches Analysis report for a comprehensive view of breaches impacting Non-Human Identities including AI Agents.


NHI Mgmt Group analysis

AI gateway traffic inspection is becoming an identity control, not a monitoring feature. The gateway already represents an access chokepoint for models, but the real risk sits inside the interaction where prompts, responses, and tool calls can move sensitive material or adversarial instructions. That makes content-level enforcement part of the identity plane rather than a separate detection concern. Practitioners should treat AI gateway inspection as policy enforcement at runtime, not as a passive analytics layer.

AI traffic without content inspection creates a blind spot that classic routing controls cannot close. Rate limits and centralised key handling can reduce operational risk, but they do not tell you whether a model was manipulated or whether confidential data left the boundary in plain language. This is the same governance mistake seen in other non-human identity contexts: control the path, miss the payload. The practitioner conclusion is that transport visibility alone is insufficient for AI governance.

Prompt injection and jailbreak defence should be framed as untrusted input governance. The article’s model is effectively a policy engine over interaction content, and that is the right mental model for AI estates that combine humans, agents, and tools. Security teams need a named concept for this class of control. Interaction content governance: the runtime discipline of inspecting AI prompts, outputs, and tool calls for policy violations before they can influence downstream systems. Practitioners should align this to identity-led policy enforcement, not model-only moderation.

Multi-model and multi-agent estates expand the enforcement surface faster than most teams can instrument it. Once traffic is distributed across several gateways and model providers, the control problem shifts from one integration to many policy paths. That introduces consistency risk because the same security rule can be applied unevenly across environments. Practitioners should assume policy drift unless they have one enforcement model across the AI estate.

Autonomous response is useful only when the policy decision is trustworthy and explainable. Blocking, masking, and alerting at runtime can reduce blast radius, but only if the team can later prove why the action occurred and what content triggered it. That makes auditability part of the control itself, not a post-incident convenience. Practitioners should link runtime response to defensible policy criteria and preserve evidence for review.

From our research:

  • 24,008 unique secrets were exposed in MCP configuration files in 2025 alone, the protocol's first year of widespread adoption, according to The State of Secrets Sprawl 2026.
  • AI-related credential leaks surged 81.5% year-over-year in 2025, with the surrounding AI infrastructure leaking 5x faster than core LLM providers.
  • For teams extending gateway controls into agent and tool ecosystems, the relevant next read is OWASP Agentic AI Top 10.

What this signals

Interaction content governance: AI gateway programmes are converging with identity governance because the control point now sits inside the message, not just around the service. That means security teams should plan for policy enforcement that spans prompts, outputs, and tool use across every AI path they operate.

The operational signal is straightforward: if your AI stack can route traffic but cannot explain why a message was blocked, masked, or allowed, then your control model is incomplete. Teams that standardise policy context now will be better positioned to govern multi-model estates without fragmented enforcement.

As model estates expand, expect content inspection to become a baseline requirement alongside gateway routing and key management. The next maturity step is to connect runtime AI controls to identity governance, audit evidence, and incident response workflows so decisions remain defensible under review.


For practitioners

  • Inspect AI content at the gateway layer Add prompt, response, and tool-call inspection on top of routing so policy decisions are made on the interaction content, not just traffic metadata.
  • Classify tool calls as governed actions Treat any model-initiated action that reaches external systems as a policy-bearing event and apply controls before execution continues.
  • Unify logging for forensic reconstruction Record what was sent, what was returned, which policy applied, and what action was taken so security review can reconstruct the full decision path.
  • Standardise enforcement across gateways Apply one policy model across Kong, Portkey, LiteLLM, Envoy, and any other AI gateway so inspection rules do not drift between paths.

Key takeaways

  • AI gateway routing does not equal AI content security, because the highest-risk behaviour happens inside prompts, responses, and tool calls.
  • Security teams need runtime policy enforcement with audit context, not just centralised traffic handling and API key management.
  • The control problem for enterprise AI is shifting from visibility of movement to governance of interaction content and downstream action.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Agentic AI Top 10 and OWASP Non-Human Identity Top 10 address the attack and risk surface, while NIST CSF 2.0 set the governance and control requirements practitioners need to meet.

FrameworkControl / ReferenceRelevance
OWASP Agentic AI Top 10A1AI gateway inspection helps reduce prompt injection and tool misuse risk.
OWASP Non-Human Identity Top 10NHI-05Content inspection and key management both affect non-human identity risk surfaces.
NIST CSF 2.0PR.DS-5Runtime inspection supports data confidentiality during AI traffic handling.

Inspect prompts, outputs, and tool calls at runtime before actions reach downstream systems.


Key terms

  • AI Gateway: An AI gateway is an intermediary that routes model requests, manages access, and centralises operational controls for AI traffic. It simplifies integration, but it does not by itself understand the meaning of prompts, responses, or tool calls, which is why content inspection must sit alongside it.
  • Prompt Injection: Prompt injection is an attack technique where untrusted input manipulates a model into ignoring instructions, revealing context, or taking unsafe actions. In practice, it is a governance problem as much as a model problem because the attacker is trying to turn ordinary text into an execution path.
  • Tool Call Governance: Tool call governance is the control of model-initiated actions that reach external systems, data sources, or workflows. It matters because the model is no longer only generating content. It is making a request that can change state, so policy checks must happen before execution continues.
  • Interaction Content Governance: Interaction content governance is the runtime discipline of inspecting AI prompts, outputs, and tool calls for security and policy violations. It treats the AI conversation as a control surface, which is necessary when sensitive data, untrusted instructions, and downstream actions can all appear in the same exchange.

Deepen your knowledge

AI gateway traffic inspection and runtime policy enforcement are core topics in our NHI Foundation Level course, the industry's only accredited NHI security programme. If you are extending identity governance into AI interactions, this is a practical place to start.

This post draws on content published by Lasso Security: How Lasso Secures AI Gateway Traffic Across Kong, Portkey, LiteLLM, Envoy, and More. Read the original.

NHIMG Editorial Note
Published by the NHIMG editorial team on 2026-06-08.
NHI Mgmt Group — the independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org