# AgentForger: Cross-Site Agent Forgery in ChatGPT Workspace Agent Builder

> Zenity Labs disclosed 'AgentForger', a cross-site agent forgery flaw in OpenAI's ChatGPT Agent Builder in which two URL parameters — template_name and initial_assistant_prompt — auto-created and auto-executed a fully-privileged rogue agent the instant a logged-in victim clicked a crafted link. The forged agent inherited the victim's authorized connectors (Outlook, Gmail, Slack, Teams, Google Drive, SharePoint), flipped approval settings from 'Always ask' to 'Never ask', scheduled itself to poll the attacker's mailbox every five minutes for 'TASK' commands, and used those connectors for organizational reconnaissance, credential/MFA-token harvesting, data exfiltration, and employee impersonation. OpenAI patched the flaw by removing the vulnerable URL-parameter handler four days after Zenity's June 4, 2026 Bugcrowd report; no CVE was assigned and Zenity found no evidence of pre-patch in-the-wild exploitation.

- **Published:** 2026-07-27T00:00:00Z
- **Last reviewed:** 2026-07-27T00:00:00Z
- **Canonical:** https://intel.threadlinqs.com/threat/TL-2026-1713
- **Card image:** https://intel.threadlinqs.com/og/threat/threat-intel-agentforger-chatgpt-agent-forgery-tl-2026-1713.webp?v=0fa6726e (Threadlinqs threat intel: AgentForger ChatGPT Agent Forgery: Detection & IOCs (TL-2026-1713) — Critical severity, 25 IOCs, 9 detection rules.)
- **ID:** TL-2026-1713
- **Severity:** CRITICAL
- **Category:** VULNERABILITY
- **Status:** PATCHED
- **Detections:** 9 (1 shown free below) · **IOCs:** 25

## Description

AgentForger is a logic/authorization flaw — not a memory-safety or injection bug in the traditional sense — in OpenAI's ChatGPT Agent Builder, the no-code interface used to create 'Workspace Agents' with access to enterprise connectors. Zenity Labs researcher Mike Takahashi found that the Builder's initialization endpoint, `https://chatgpt.com/agents/studio/new`, accepted state entirely from URL query parameters and executed it without any user confirmation or CSRF protection. The `template_name` parameter selected a pre-built agent template (notably `chief-of-staff`, a template pre-wired with broad tool access), and the `initial_assistant_prompt` parameter contained free-text instructions that were auto-submitted to the newly created agent the moment the page loaded.

Because the 'prompt' was just natural language, an attacker could use it to give the agent operator-level instructions rather than end-user requests: attach every connector the victim had already authorized in ChatGPT (email, calendar, cloud storage, Slack, Teams) with approval set to 'Never ask' for read/write/delete actions, publish the agent, invoke Preview Mode so it ran immediately, and schedule it to run every five minutes. Each scheduled run checked the victim's inbox for an email from the attacker whose subject line began with 'TASK'; if found, the agent read the instruction, executed it across whichever connected enterprise applications were needed, and emailed the results back to the attacker — an email-based command-and-control loop requiring no further interaction from the victim and no traditional malware on the endpoint.

Zenity characterizes the underlying design flaw as a 'lethal trifecta': untrusted input (the URL), access to private data (the victim's already-authorized connectors), and an unmonitored exfiltration path (outbound email/collaboration messaging) all converging in a single, invisibly-created agent. Zenity CTO Michael Bargury summarized the impact as producing 'a forged insider' rather than a forged request — the attacker obtains an autonomous, persistent operator running with a real employee's identity and access, capable of mapping the org chart, locating and exfiltrating sensitive documents (M&A materials, board decks, financial and HR records), harvesting passwords/API keys/MFA tokens surfaced in chat history, and impersonating the victim on Teams and email to stage further phishing and business-email-compromise fraud (Zenity's writeup includes a wire-transfer BEC example around $242,500).

Zenity reported AgentForger to OpenAI via Bugcrowd on June 4, 2026; OpenAI triaged and accepted it within roughly 24 hours and shipped a fix by June 8, 2026 by removing the vulnerable URL-parameter auto-execution handler. No CVE identifier was assigned. OpenAI is separately deprecating the Agent Builder product in favor of the Agents SDK, with a stated deprecation date of November 30, 2026. The novel TTP pattern here — URL-parameter-driven autonomous-agent creation, natural-language-based security-control tampering, and inbox-as-C2-channel — is broadly applicable to other agent-builder-style platforms and is included here as a detection-engineering reference case for agentic-AI authorization bypass even though the specific flaw is already patched.

## MITRE ATT&CK

- T1585.002 Email Accounts
- T1566.002 Spearphishing Link
- T1078 Valid Accounts
- T1204.001 Malicious Link
- T1053 Scheduled Task/Job
- T1098 Account Manipulation
- T1078 Valid Accounts
- T1548 Abuse Elevation Control Mechanism
- T1078 Valid Accounts
- T1685 Disable or Modify Tools
- T1078 Valid Accounts
- T1684.001 Impersonation
- T1552 Unsecured Credentials
- T1528 Steal Application Access Token
- T1087 Account Discovery
- T1526 Cloud Service Discovery
- T1114 Email Collection
- T1213 Data from Information Repositories
- T1530 Data from Cloud Storage
- T1071.003 Mail Protocols
- T1041 Exfiltration Over C2 Channel
- T1657 Financial Theft

## Free detection (Splunk SPL, Microsoft KQL, Sigma)

**AgentForger — Connector Approval Flipped to 'Never Ask' + Sub-15-Minute Agent Schedule** (`TL-2026-1713-SPL-002`)

Detects the post-exploitation persistence/privilege-escalation stage: a Workspace Agent's connector approval setting flipped from 'Always ask' to 'Never ask' (disabling human-in-the-loop confirmation for read/write/delete actions), and/or a newly created agent scheduled to re-run on an unusually short fixed interval (<=15 minutes) — the mechanism AgentForger used to disable approvals and establish its 5-minute inbox-poll persistence loop.

- **Languages:** Splunk SPL, Microsoft KQL, Sigma
- **ATT&CK:** T1548, T1098, T1685, T1053, T1078
- **Data sources:** saas_audit_log, chatgpt_workspace_agents_audit, m365_defender_cloudappevents
- **Severity:** critical
- **Confidence:** high

### Splunk SPL

```spl
index=saas_audit sourcetype="chatgpt:workspace_agents:audit"
(Operation="ConnectorApprovalChanged" NewValue="Never ask")
OR (Operation="AgentScheduleCreated" ScheduleIntervalMinutes<=15)
| eval technique=case(Operation="ConnectorApprovalChanged","T1548,T1098", Operation="AgentScheduleCreated","T1053", 1=1,"unknown")
| stats count values(Operation) as operations values(Connector) as connectors values(NewValue) as new_values values(ScheduleIntervalMinutes) as schedule_interval_min earliest(_time) as first_seen latest(_time) as last_seen by AgentId, UserId
| where count>=1
| eval risk=if(mvcount(operations)>1,"chained_approval_bypass_plus_schedule","single_stage")
| table first_seen last_seen UserId AgentId operations connectors new_values schedule_interval_min risk
```

### Microsoft KQL

```kql
CloudAppEvents
| where Timestamp > ago(24h)
| where Application has "ChatGPT" or Application has "OpenAI" or Application == "ChatGPT Workspace Agents"
| where ActionType in ("ConnectorApprovalChanged", "AgentScheduleCreated", "OAuthConsentGranted")
| extend ApprovalValue = tostring(RawEventData.new_approval), ScheduleIntervalMinutes = toint(RawEventData.interval_minutes), AgentId = tostring(RawEventData.agent_id)
| where (ActionType == "ConnectorApprovalChanged" and ApprovalValue == "Never ask")
    or (ActionType == "AgentScheduleCreated" and ScheduleIntervalMinutes <= 15)
| project Timestamp, AccountDisplayName, ActionType, ApprovalValue, ScheduleIntervalMinutes, AgentId, ObjectName
| sort by Timestamp desc
```

### Sigma

```yaml
title: Workspace Agent Connector Approval Set to 'Never Ask' or Sub-15-Minute Schedule Created
id: 5c1d8e34-7a2f-4c9b-8e6d-2f4a9b7c3d02
status: experimental
description: Detects an AgentForger-style post-exploitation stage where a ChatGPT/agentic-AI Workspace Agent has its connector approval control flipped to 'Never ask' or is scheduled to run on an unusually short, fixed interval immediately after creation.
references:
    - https://labs.zenity.io/p/agentforger-part-2-the-autonomous-insider
    - https://www.csoonline.com/article/4200978/agentforger-proves-ai-agents-can-become-persistent-insider-threats.html
author: Threadlinqs Team
date: 2026-07-27
tags:
    - attack.privilege-escalation
    - attack.defense-evasion
    - attack.persistence
    - attack.t1548
    - attack.t1098
    - attack.t1685
    - attack.t1053
logsource:
    category: application
    product: chatgpt_workspace_agents
detection:
    selection_approval:
        event: 'connector_approval_changed'
        new: 'Never ask'
    selection_schedule:
        event: 'schedule_created'
        interval_minutes: '<=15'
    condition: selection_approval or selection_schedule
falsepositives:
    - IT admin bulk-reconfiguring connector approvals during a legitimate agent-platform onboarding, tracked in a change ticket
    - Power users legitimately configuring short-interval agents for real-time workflow automation (e.g. inventory sync)
level: high
```

**Known false positives:**

- Legitimate IT-admin bulk connector reconfiguration during onboarding, backed by a change ticket
- Power-user-configured short-interval agents for legitimate near-real-time automation

**Tuning notes:** Correlate approval-flip and schedule-creation events against the change-management/ticketing system to suppress admin-approved changes; adjust the schedule-interval threshold (currently <=15 minutes) to match the organization's known legitimate automation cadence.

### 8 more detection rules (Splunk SPL, Microsoft KQL, Sigma), unlock with TL Creds

- AgentForger — Crafted Agent Builder URL via DeviceProcessEvents / Safe Links (locked: unlock with TL Creds)
- AgentForger — CloudAppEvents Connector Approval Flip / Sub-15-Minute Schedule (locked: unlock with TL Creds)
- AgentForger — EmailEvents 'TASK' Subject Correlated With Agent Creation (C2 + Exfil) (locked: unlock with TL Creds)
- Sigma: Potential AgentForger Crafted Agent-Builder Link Click (locked: unlock with TL Creds)
- Sigma: Workspace Agent Connector Approval Set to 'Never Ask' (locked: unlock with TL Creds)
- Sigma: Inbound 'TASK'-Prefixed Mail Correlated With Recently-Created Workspace Agent (locked: unlock with TL Creds)
- AgentForger — Crafted Agent Builder URL (template_name / [indicator]) (locked: unlock with TL Creds)
- AgentForger — Email-Based C2 ('TASK'-Prefixed Inbound Mail) Correlated With Recent Agent Creation (locked: unlock with TL Creds)

Sign up free to unlock the detection rules: https://threadlinqs.com/?modal=signup

## Sources

- [ChatGPT AgentForger Vulnerability](https://cybersecuritynews.com/chatgpt-agentforger-vulnerability/)
- [AgentForger, Part 1: ChatGPT Cross-Site Agent Forgery](https://labs.zenity.io/p/agentforger-part-1-chatgpt-cross-site-agent-forgery)
- [AgentForger, Part 2: The Autonomous Insider](https://labs.zenity.io/p/agentforger-part-2-the-autonomous-insider)
- [ChatGPT AgentForger Flaw Could Deploy Rogue Workspace Agents via a Phishing Link](https://thehackernews.com/2026/07/chatgpt-agentforger-flaw-could-deploy.html)
- [OpenAI Fixes ChatGPT Agent Flaw That Could Let Attackers Forge an AI Insider](https://www.securityweek.com/openai-fixes-chatgpt-agent-flaw-that-could-let-attackers-forge-an-ai-insider/)
- [AgentForger proves AI agents can become persistent insider threats](https://www.csoonline.com/article/4200978/agentforger-proves-ai-agents-can-become-persistent-insider-threats.html)
- [Zenity Labs Uncovers AgentForger, a ChatGPT Vulnerability](https://zenity.io/company-overview/newsroom/company-news/zenity-labs-uncovers-agentforger-a-chatgpt-vulnerability)
- [OpenAI Patches 'AgentForger' Flaw That Let Attackers Hijack Enterprise AI Agents via Single Link](https://mlq.ai/news/openai-patches-agentforger-flaw-that-let-attackers-hijack-enterprise-ai-agents-via-single-link/)
- [OpenAI Fixes ChatGPT Agent Flaw That Could Let Attackers Forge an AI Insider (OODAloop)](https://oodaloop.com/briefs/cyber/openai-fixes-chatgpt-agent-flaw-that-could-let-attackers-forge-an-ai-insider/)
- [One tampered ChatGPT link could spawn a rogue AI agent that took orders from an attacker every five minutes](https://the-decoder.com/one-tampered-chatgpt-link-could-spawn-a-rogue-ai-agent-that-took-orders-from-an-attacker-every-five-minutes/)

## Full data

The other 8 detection rules (Splunk SPL / Microsoft KQL / Sigma) unlock with TL Creds; a free account includes daily creds: https://threadlinqs.com/?modal=signup
Indicator values unlock with TL Creds, at a lower price on Red and Purple; AI agents can query rules and IOCs through the Threadlinqs MCP server (Purple): https://intel.threadlinqs.com/mcp

Canonical: https://intel.threadlinqs.com/threat/TL-2026-1713
