Submit

ChatGPT fixes a shared-link bug that hijacked accounts

OpenAI fixed a ChatGPT bug that let a malicious shared chat link run code in a victim's session and read private conversations, Parameter Security found.

Written by AiAgentsListing Team

ChatGPT fixes a shared-link bug that hijacked accounts

Security researchers at Parameter Security found a way to take over a ChatGPT account just by getting the victim to open a shared conversation link. The chain combined ChatGPT's HTML Preview feature, the MathLive math-keyboard library, and a YouTube endpoint to run attacker JavaScript inside the victim's signed-in session. OpenAI rated the report P1, shipped a server-side fix on 26 October 2026, and paid a $5,000 bounty.

The ChatGPT account takeover bug let an attacker who published an ordinary public chat share run JavaScript inside anyone who opened it, as chatgpt.com. The code could list a victim's conversations, read a private one that was never shared, and send data to an external server using nothing but the authenticated session the browser already held.

What changed

OpenAI closed a chain that let a public ChatGPT share run code in a visitor's signed-in session, by rejecting the cross-frame messages the attack depended on. A graph in a ChatGPT conversation loaded the MathLive library into the main chatgpt.com page, which installed a postMessage listener for its on-screen math keyboard. The listener's origin check was set to "none," so it accepted a keyboard-layout update from any web address, including the sandboxed HTML Preview frame. The attacker's Preview sent a layout containing raw HTML, and MathLive wrote it into the page's innerHTML through a helper called createHTML that was supposed to sanitize the value; according to Parameter Security's write-up, it instead marked the string as trusted and passed it through unchanged. The injected HTML created an iframe with a srcdoc attribute and no sandbox attribute, so the new document inherited the chatgpt.com identity. ChatGPT's content security policy blocks inline scripts but allows www.youtube.com, and the frame loaded YouTube's oEmbed endpoint with a JSONP callback parameter carrying the attacker's code, which the endpoint echoed back as executable JavaScript ahead of its own validation-error message. With code now running as chatgpt.com, the payload called GET /backend-api/conversations and GET /backend-api/conversations/ using the victim's bearer token, then sent a value from the response to an external server through an ordinary image request.

Parameter Security submitted the report to OpenAI's bug bounty program on 18 October 2026. OpenAI reproduced the issue, raised its severity from an initial P2 to P1 on 21 October, and confirmed on 26 October that both versions of the ChatGPT web frontend rejected the messages the attack relied on, paying a total bounty of $5,000.

Parameter Security's disclosure timeline table, showing the exploit chain confirmed on 13 October 2026, reported to OpenAI's bug bounty program on 18 October, and both ChatGPT frontends fixed with a $5,000 bounty paid on 26 October 2026.

Why it matters for agent builders

This bug matters for agent builders because it was a web sandbox escape rather than a prompt-injection flaw, built from features that each looked safe when tested alone: an isolated preview frame, a math-keyboard listener, an unsandboxed iframe, and a content security policy with one allowed third-party endpoint. The same pattern applies to any product that renders agent-generated or user-generated HTML next to a privileged, authenticated page: code execution tools, MCP servers that return HTML or UI from a tool call, and coding agents with live previews all depend on the same cross-frame isolation holding under combination, not just in each feature on its own.

The bug reaches past ChatGPT itself: Ostorlab's follow-up analysis, published 31 October 2026, points out that any site embedding the MathLive library carries the same unchecked listener, and that the public disclosure does not name a specific patched MathLive version. Ostorlab notes npm lists v0.111.1 as latest while GitHub Releases still shows v0.100.0, so a version number alone does not confirm a fix. Anyone who embeds MathLive should check how their own message handlers validate event.origin and event.source.

Ostorlab's TL;DR summary of the ChatGPT account takeover disclosure, stating Parameter Security reported the chain to OpenAI on 18 October 2026 and OpenAI shipped a server-side fix on 26 October 2026 with no CVE assigned and no reported real-world abuse.

What to watch

OpenAI's fix covers chatgpt.com only, so the open question is how many other products that embed MathLive, or that pass messages between a sandboxed preview and a privileged parent page, carry the same unchecked listener. No CVE has been assigned to the bug as of Ostorlab's 31 October 2026 write-up, and neither Parameter Security nor Ostorlab reports evidence it was exploited outside of controlled testing.

Key takeaways

  • Parameter Security chained a sandboxed ChatGPT HTML Preview, an unchecked MathLive postMessage listener, an unsandboxed srcdoc iframe, and a YouTube JSONP endpoint to run JavaScript as chatgpt.com inside a victim's signed-in session.
  • The most reliable reproduction needed one click on ChatGPT's own Preview button; a later version triggered automatically when the victim opened the shared link, reproduced three times including after a hard refresh.
  • The attacker's code could enumerate a victim's conversations, read a private conversation that had never been shared with them, and exfiltrate data, using the same authenticated access as the real ChatGPT frontend.
  • OpenAI rated the report P1, fixed both ChatGPT web frontends by 26 October 2026, and paid a $5,000 bounty; no CVE has been assigned and no in-the-wild exploitation has been reported.
  • Anyone embedding the MathLive library in their own product carries the same listener and should check their own message handlers, per Ostorlab's 31 October 2026 follow-up.

FAQ

Do ChatGPT users need to do anything about this bug?

No. OpenAI's fix is server-side and was already deployed across both versions of the ChatGPT web frontend by 26 October 2026, so there is nothing for a user to install, reset, or reconfigure.

Was the ChatGPT account takeover bug exploited before it was fixed?

Parameter Security ran its proof-of-concept only between accounts it controlled, and both Parameter Security and Ostorlab's follow-up report no evidence of real-world abuse.

In the version Parameter Security reproduced automatically, including after a hard refresh, opening the attacker's shared link was the only action required. An earlier, more stable version needed one click on ChatGPT's own Preview button first.

What was the root cause of the ChatGPT account takeover bug?

The MathLive library, loaded into the main ChatGPT page by an interactive graph, accepted a postMessage with an origin check set to "none" and let the message's HTML be assigned directly to innerHTML, giving an untrusted Preview frame a path to inject and run code inside the signed-in parent page.

Source: Parameter Security Discussion: Hacker News

Developers building sandboxed tool-output renderers or MCP servers that return HTML can browse what is already listed on AI Agents Listing's MCP servers hub.

Share:

Subscribe to our newsletter

One email a week. New agents, MCP servers and skills, and what is actually getting traction.

More news

  1. ClawDOS ships as an open source AI coding agent for DOS

    ClawDOS is an open source AI coding agent harness running Claude's Messages API on a real 1980s IBM PC, posted to Hacker News on 21 November 2026.

  2. Turbo-Browser-MCP ships as an 11-tool Playwright MCP server

    Turbo-browser-mcp is a new open-source Playwright MCP server with 11 tools that batches browser actions to cut token use and model turns for AI agents.

  3. Windows 11 diagnostics flag Claude Code, Codex and Cursor

    A Windows 11 component called MissionControlAggregator checks for Claude Code, Codex, Cursor and other coding agents, researcher Xusheng Li found on 16 November 2026.