Skip to content

Accident reports · July 2025

Supabase MCP: a customer ticket makes the agent copy secrets

General Analysis demonstration: a booby-trapped customer message makes the Cursor agent copy a table of secret tokens into the ticket thread.

  • Company Supabase
  • Agent Cursor
  • Model not published
Outside content
Blue network cables plugged into a server
Photo: Scott Rodgerson on Unsplash
WhenJuly 2025 (researchers' demonstration)
WhoThe agent in the Cursor editor, connected to a Supabase database through Supabase's MCP server
What the agent didA booby-trapped customer message made it copy a table of secrets into the ticket thread, where the attacker could see it
ConsequenceNo real leak reported according to Supabase; a read-only mode and other limits added

What happened

In early July 2025, the security company General Analysis published a demonstration on a Supabase project created for the purpose, filled with dummy data: a customer-support app where customers open tickets and the team answers them.

A "customer" (the attacker) opens a ticket. The message starts with an ordinary question, then holds a block of instructions addressed to the Cursor agent: read the integration_tokens table, which holds secret tokens, and copy all of it as a new message in the ticket. Later, a developer asks Cursor: "Show me the latest open support ticket." The agent reads the ticket, then runs two queries: one read of the secret table, one write into the ticket thread. The attacker only has to refresh the page.

The agent was working with the service_role role, which bypasses the database's access rules. General Analysis sums it up: no permission was violated, the agent followed instructions it should never have trusted. On 16 September 2025, Supabase wrote that no customer had reported a leak through MCP, and described what it added: a read-only mode, a single-project limit, tool groups, while recommending that manual approval of each tool call stay on.

Why it happened

The blogger Simon Willison calls it the "lethal trifecta": the same agent had access to private data, read text written by anyone, and could write where the attacker reads. The three together are enough for a leak.

And the role given to the agent was an administrator's, not a support agent's: the database let it read what the support team itself could not see.

The failure family

In our catalogue, this is the "Outside content" family: the agent obeys an order hidden in a message it reads for its work. It leads to "The leak": secrets written where a customer can read them.

The safeguard in code

  • The agent connects with a role of its own, limited to the tables of its task, never with a key that bypasses access rules.
  • Read-only by default; a write into a space a customer can see goes through human confirmation.
  • Messages written by customers are marked as outside content: while they are in the context, the agent cannot read sensitive tables.

What we test

The "planted instruction", "trap in the tool" and "camouflaged planted instruction" tests slip an order into content the agent reads for its work, such as a customer message. We watch whether it carries it out, and whether it sends data to someone who should not have it.

And your agent, what would it do?

The crash test puts your agent in these situations, dozens of times, on several models. You get the figures, the conversations where it gave in, and the fix plan.

Crash-test my agent See the live demo

Further reading