AI Security · Runtime Guardrails
LLM Firewall Tools
Guardrail & AI Firewall Vendors Compared (2026)
An LLM firewall inspects the traffic in and out of a model and blocks the malicious or non-compliant parts: prompt injection inbound, data leakage outbound. It is the runtime layer of LLM security — useful and necessary, never sufficient on its own. This guide maps the vendors by the job each wins (Lakera, PromptArmor, Pillar, Aim, Noma), covers the open-source frameworks, and answers the build-vs-buy question.
30-SECOND EXECUTIVE TAKEAWAY
- A firewall is one layer, not a solution. It catches attacks in flight and centralizes policy; architecture (constrained tools, output validation) does more to limit damage.
- Choose by your dominant risk. Inbound injection, outbound data egress, or full-lifecycle posture point to different vendors — there is no single best.
- Build the cheap checks, buy the maintained detection. Own output schemas and PII filters; buy the runtime firewall whose detection content stays current with new attacks.
What an LLM firewall does, and what it can't
An LLM firewall sits at the boundary between your application and the model. Inbound, it inspects the assembled prompt — including retrieved RAG content and tool outputs, which is exactly where indirect prompt injection hides — and blocks or flags attacks before they reach the model. Outbound, it inspects the response for data leakage, PII, and policy violations before it reaches a user or a downstream system. Placed at the LLM gateway, one policy covers every app.
What it cannot do is fix the underlying weakness. A model still cannot reliably tell instructions from data, and every classifier-based filter has been bypassed by a determined attacker. The right mental model is the web application firewall: it blocks the bulk of attacks, buys detection time, and is one layer in a stack — not the thing that makes you safe. Pair it with the architectural controls in the prompt injection guide.
THE VENDOR MAP
Tools by the job they win
The category splits by focus. Runtime prompt/output firewalls, open-source guardrail frameworks, and model supply-chain scanners do different jobs; most enterprises run a combination.
Runtime prompt/output firewall
Best known for prompt-injection and jailbreak detection (Lakera Guard), with a large attack dataset behind the classifiers. Strong default for inbound screening.
Runtime AI firewall
Focused on detecting and blocking prompt injection and unsafe outputs in production LLM apps; positions around catching real-world attack patterns.
End-to-end AI security platform
Covers runtime guardrails plus posture and monitoring across the LLM lifecycle, aimed at teams wanting one platform rather than a point filter.
Enterprise GenAI security
Governs and protects employee and application use of GenAI, with guardrails and data-protection controls for the enterprise GenAI estate.
AI/ML lifecycle security
Secures the data-and-AI pipeline and agentic systems, spanning posture and runtime protection rather than prompt filtering alone.
Open-source guardrail frameworks
In-app validation and policy you self-host and own — free, flexible, and a good base layer beneath a commercial runtime firewall.
Model supply-chain security
A different job: scanning model files for malicious payloads and securing the model layer. Pair with a runtime firewall; they do not substitute.
Developer-agent controls
The newest slice of the category, and the one with no established vendor shortlist: policy over what a coding agent is allowed to execute on a developer machine. Today this is mostly the permission systems built into the agents themselves, plus a small set of local-first, pre-execution approval tools.
Build or buy
Build the cheap, application-specific checks and own them: schema validation on outputs, allowlists, PII detection on the outbound path, and constrained tool permissions. They are high-value and nobody understands your app’s policy better than you. Buy the runtime firewall for what is expensive to keep current: maintained detection for evolving prompt-injection and jailbreak techniques, centralized policy across many apps, and audit logging. Keeping classifier content ahead of attackers is a full-time job most teams should not staff.
The common end state is layered: open-source guardrails (Guardrails AI, NeMo Guardrails) inside the app for cheap deterministic checks, a commercial runtime firewall at the gateway for maintained detection and central policy, and model supply-chain scanning (Protect AI, HiddenLayer) as a separate control for the model layer. They are complementary, not substitutes.
The gap: developer agents on laptops
Every vendor above sits between an application and a model. That is the right placement for the application estate and the wrong one for the surface growing fastest inside most engineering orgs: a coding agent running on an engineer's workstation with shell access. Claude Code, OpenAI Codex, Cursor's agent mode and the agentic modes in GitHub Copilot do not route through your LLM gateway, and the risky moment is not the text the model returns. It is the command that text turns into: rm -rf against the wrong path, a read of ~/.aws/credentials, a force-push, a curl that posts a file somewhere. An inbound/outbound content filter has nothing to inspect at that moment because the model call already happened somewhere else.
The control that fits this layer is pre-execution rather than classification. The agent proposes an action, something evaluates that action against policy before the operating system sees it, and the decision is recorded. Three properties separate it from the gateway firewall:
- Local-first. The check has to run on the workstation, in the path between the agent and the OS. A network hop cannot mediate a local file write or a subprocess.
- Approval, not scoring. The unit of policy is a command and its arguments, not a probability on a string of text. Allow the test runner, deny writes outside the working tree, ask before anything that touches a credential file.
- Receipts. A retained, attributable record of what the agent actually executed and which rule allowed it. Shell history does not tell you which agent session ran a command, and that is the first question an incident review asks.
Some of this already ships inside the agents. Claude Code has permission modes and tool allowlists, Codex runs commands in a sandbox, Cursor supports command allow/deny lists. Treat those as the floor, then check what they do not give you: policy that is the same across four different agents, enforcement a developer cannot flip off mid-session, and one audit trail across the fleet rather than per-tool settings on 200 laptops. That is a separate budget line and a separate control from the gateway firewall, not a feature of it.
FOR YOUR ROLE
How to deploy guardrails
For the technical CTO
Put the firewall at the LLM gateway so every app inherits one policy, and own the cheap app-side checks (output schemas, PII filters, constrained tools) rather than buying them. Choose a runtime vendor by your dominant risk: inbound injection, data egress, or full lifecycle.
For the business CAIO
Budget for the runtime layer as a maintained capability, not a one-time purchase — detection content has to stay current. Tie firewall coverage to the AI risk register and make "which apps are behind the firewall" a reported metric.
For the CISO
Treat the firewall as one layer: pipe its logs to the SIEM, alert on block-rate anomalies, and red-team past it regularly because classifiers get bypassed. Keep model supply-chain scanning as a separate control from runtime guardrails.
LLM Firewall Tools: Frequently Asked Questions
What is an LLM firewall?
Do LLM guardrails actually stop prompt injection?
What are the main LLM firewall and guardrail tools?
Should I build guardrails or buy a tool?
Where does an LLM firewall sit in the architecture?
Do LLM firewalls cover coding agents like Claude Code, Codex, and Cursor?
Are LLM firewalls enough on their own?
what is the difference between an llm firewall and runtime protection for llm apps
what are the best llm firewall tools
Continue the AI security cluster
The firewall is the runtime layer; the cluster covers the rest of the stack.