Agentic Browser Security: Risks and Controls

Surface Security Team

Agentic browser security stops AI browsers and browser agents from being turned against the logged-in user. Here are the risks and the controls that work.

Agentic browser security is the set of controls that keeps an AI agent acting inside a real, logged-in browser session from being turned against the person or company it works for. The main risks are prompt injection from page content, credentials and sessions used where they should not be, data sent to destinations nobody approved, and actions nobody can attribute afterward.

Those risks apply to two kinds of agent. The first is the AI browser or browser assistant from an AI vendor, such as OpenAI's ChatGPT Atlas, Perplexity's Comet, or Anthropic's Claude for Chrome, which an employee can point at their own inbox. The second is the automation your own teams build on Playwright, Puppeteer, Selenium, Browser Use, or Stagehand. We covered protecting that second group in Agentic AI Security: Protecting Your AI-Powered Browser Agents. This post looks at the whole category: what makes it risky, and what a sensible control set looks like.

Why an agentic browser is a different risk

A normal browser shows you a page and waits. An agentic browser reads the page, decides what to do, and does it: clicks, types, submits forms, opens tabs, and moves between sites. It does all of that with whatever sessions are already signed in.

Simon Willison's lethal trifecta is the clearest way to see the problem. An agent becomes dangerous when it combines access to your private data, exposure to untrusted content, and the ability to communicate externally. An AI browser has all three by default. Your mail, CRM, and admin consoles are open in the same session. Every web page is untrusted content. And a browser exists to send requests to other sites.

Most browser controls were built around a human making the final call. A phishing warning assumes someone will read it. A DLP prompt assumes someone will reconsider a paste. An agent working at machine speed does not pause for either.

The attack surface

Prompt injection

The agent cannot reliably tell your instruction apart from text it reads on a page. Brave's researchers showed this against Comet in August 2025: instructions hidden behind a spoiler tag in a Reddit comment ran when the user asked Comet to summarize the page. The agent fetched the user's email address from their Perplexity account page, requested a one-time password, read it from the user's open Gmail, and posted both back as a reply to the comment. We break down the techniques in Prompt Injection in AI Browsers: How It Works.

Credential and session exposure

An agent that can sign in, autofill a password, or ride an existing session cookie can use that access wherever it is told to go. A lookalike domain, a redirect, or an injected instruction can all point it at the wrong origin. Credential and Autofill Guardrails for AI Agents covers how agents get credentials and how those credentials leak.

Data exfiltration

Agents read internal pages to do their jobs. If something hijacks the agent, that same data can leave in a form post, a URL parameter, a comment, or a background request. To network tools, the request looks like any other browser traffic from that user.

No attribution

When an agent acts in your session, the logs show your account. The SaaS audit trail says you sent the email, approved the change, or downloaded the file. Without a marker on agent traffic, an analyst cannot separate what the person did from what the agent did, and incident response turns into guesswork.

Model defenses help, but they are not enough

The AI vendors are candid about this. Anthropic reported that across 123 test cases in 29 attack scenarios, browser use without safety mitigations had a 23.6% attack success rate, and its new mitigations brought that to 11.2% in autonomous mode. That is real progress, and it still means some attacks land. OpenAI's post on hardening Atlas puts it plainly: "Prompt injection, much like scams and social engineering on the web, is unlikely to ever be fully 'solved'."

The takeaway for a security team: treat the model as a component that will sometimes be fooled, and put controls around it that do not depend on the model making the right call.

The control set

Five controls cover most of the risk, and each one works whether or not the model gets tricked.

RiskControlWhat it gives you
Unknown agents in the fleetIdentify agent trafficAn inventory, and a way to tell agent actions from human
Prompt injectionSanitize injected instructionsHidden payloads removed before the model reads the page
Credential misusePin credentials to originsA credential that only works on the site it belongs to
ExfiltrationAllowlist destinationsAn alert when data heads somewhere unapproved
Attribution gapsLog every action with agent identityA trail of which agent did what, and where

Identify agent traffic. Detection starts with an inventory. Standalone AI browsers are separate applications, so your endpoint management tool's software inventory is the place to find them. Agent extensions inside Chrome or Edge show up in an extension inventory. For agents you run yourself, tag every outbound request with an identifier so downstream systems can tell agent traffic from people.

Sanitize injected instructions. Scan the page before the agent reads it and strip content a human cannot see: CSS-hidden text, invisible Unicode, HTML comments. This will not catch every attack, since some injections sit in plain visible text, but it removes the cheapest tricks.

Pin credentials to origins. A credential provisioned for one site should be unusable anywhere else, no matter what the page or the prompt says.

Allowlist destinations. An agent that files expense reports needs a handful of domains. Anything outside that list is either a bug or an attack, and both deserve an alert.

Log every action. Record what the agent saw, what it did, which origin it touched, and what got stopped, tied to an agent ID your SOC can query.

Two practices from the vendors' own guidance round this out. Brave recommends explicit user confirmation for sensitive actions such as sending email, and isolating agentic browsing from regular browsing. OpenAI recommends logged-out mode and narrow, well-scoped tasks. In enterprise terms: give agents their own profile with only the sessions the task needs.

How Surface handles agentic browsing

Surface runs as an extension in Chrome, Edge, and Firefox, and its agent protections work with Playwright, Puppeteer, Selenium, Browser Use, Stagehand, or a custom framework. For agents running with Surface:

  • Agent traffic is tagged with a watermark header, so every action traces back to the agent that took it.
  • Prompt injection is detected and sanitized, including hidden CSS text, Unicode steganography, and HTML comments.
  • Domain allowlists raise exfiltration and domain-violation alerts.
  • Credentials are origin-locked by default (credential pinning).

Extension monitoring inventories every installed extension, AI agent extensions included, gives each a 0 to 100 risk score, and can enforce an allowlist that disables everything else. The control plane is self-hosted, so browsing telemetry and the detection engine stay in your environment. The argument for that architecture is in Your AI Agents Belong Inside Your Perimeter.

Read the agentic AI technology overview or the agentic AI browser security use case. If your agent problem is really employees adopting AI tools on their own, start with What Is Shadow AI?