AutoJack Exploit in Web-Enabled AI Agents: Bypassing Localhost Security

Microsoft uncovers RCE vulnerability in AutoGen Studio through local AI agent misuse.

ThreatVectr Newsdesk· 2 min read
AutoJack Exploit in Web-Enabled AI Agents: Bypassing Localhost Security
Share

Microsoft recently demonstrated a remote code execution (RCE) vulnerability exploiting web-enabled AI agents, specifically targeting AutoGen Studio. This open-source platform, designed for building and testing multi-agent applications, became the testing ground for a vulnerability dubbed 'AutoJack'. It allows a malicious webpage to exploit a browsing agent to reach and execute arbitrary processes on a host machine.

The attack combines three distinct flaws in AutoGen Studio’s Model Context Protocol (MCP) WebSocket implementation. The first involves an origin allowlist that should restrict connections to localhost. However, a local browsing agent inherits localhost privileges, permitting malicious JavaScript to bypass this check.

Secondly, AutoGen Studio’s authentication logic naively excluded MCP WebSocket paths from the usual checks, assuming they would self-regulate. Unfortunately, these assumptions fell apart, leaving the endpoints open to unauthorized access.

The third, most dangerous flaw, involves the MCP endpoint's acceptance of a 'server_params' value from a URL, which it decodes and executes. Without an executable allowlist, this opens the door to launching any command, including PowerShell or Bash.

Chaining these vulnerabilities allows an attacker to execute arbitrary commands merely by getting an agent to render a malicious webpage. Microsoft's research indicates this pattern of an agent accessing localhost services is not unique to AutoGen, suggesting broader implications for agentic frameworks.

Fortunately, the affected code was confined to development builds and never reached PyPI releases, meaning users of the public release were not exposed. Following the discovery, fixes included removing URL-based parameter injection and tightening authentication and command handling protocols.

These findings highlight a critical intersection of traditional software risks and modern AI capabilities. Microsoft's continued investment in agent governance and containment reflects its commitment to securing these evolving technologies.

© 2026 Threat Vectr