By Jens Ernstberger.
Published 2026-11-17.
On October 29, Cursor removed tampered builds of Anthropic’s Claude Code extension from its VS Code extension marketplace. The first notice focused on the extension. Cursor’s November 13 update picked up the story earlier, in a shared storage bucket holding traces from old coding sessions. Cursor’s initial notice · November 13 update
How old traces led to access beyond the bucket
Cursor says an access key it had issued to Fireworks was exposed. The attacker used it to copy data from a read-only bucket Cursor shared with Fireworks for model training. A small number of those coding-agent traces held working credentials, which the attacker used to reach some of Cursor’s internal SaaS tools. Cursor’s investigation
Those tools gave the attacker access to some archived, non-production Cursor repositories and limited customer support records, among other internal data. On October 29, the attacker used another credential from the exposed internal data to put altered copies of the Claude Code extension in Cursor’s marketplace cache. Cursor says the copies were available for about 11 hours and that up to 5,000 users may have received one. Cursor’s investigation
The traces in the bucket came from sessions outside Privacy Mode and were mostly from 2025. Cursor estimated that API credentials were exposed for fewer than 0.01% of its customers. Fireworks’ own November 9 bulletin reported that secrets and datasets had been affected for a limited set of its accounts. Cursor’s exposure assessment · Fireworks’ November 9 bulletin
The vendor key let the attacker read one dataset. The credentials inside it let them authenticate to other systems. A trace should tell an investigator which database the agent targeted while leaving out the password that would let a reader connect to it.
How a credential gets into a tool trace
Cursor’s update describes the exposed credentials at the trace level. A shell call makes it easier to see how a credential can get into one. Imagine a developer asking a coding agent to run a migration against a test database.
The application running the agent gives the model a set of tools it can request. In this example the model chooses Bash and supplies a command. The application decides whether to allow the call. If it runs the command, it can return the exit status and output to the model for the next step. How tool use works
There is already something to log before Bash starts. A pre-execution hook is code the application calls with the requested tool and its arguments. Here are the relevant fields of a synthetic hook event, with a fake password and a test hostname. PreToolUse hook reference
{
"hook_event_name": "PreToolUse",
"tool_name": "Bash",
"tool_use_id": "toolu_postgres",
"tool_input": {
"command": "DATABASE_URL=postgres://app:[email protected]:5432/app ./migrate"
}
}The command sets DATABASE_URL for the migration program. The hostname and password arrive together in one argument, so a logger that copies tool_input.command picks up both. The password could end up in storage even if the permission check stops the command from running.
A week later, someone investigating the migration wants to know which database the agent targeted. The redacted command summary still answers that question.
DATABASE_URL=postgres://[REDACTED_SECRET]@db.example.test:5432/app ./migrateThe summary tells the reviewer where the agent meant to run the migration. To find out what happened, they can use the tool call ID to look for the corresponding result. If they need to know whether the database actually changed, they can check the database's own records.
Decide which fields belong in the log
Start with what an investigator needs to reconstruct the action. For the migration, record the tool name, the destination, and a call ID that can link the request to its result. Include the timestamp, permission decision, and exit status when available and relevant to the investigation. OWASP logging guidance
Here is one possible record for the request itself.
{
"event": "tool_requested",
"tool_name": "Bash",
"tool_use_id": "toolu_postgres",
"destination_host": "db.example.test"
}The hostname answers the question in this example. If the team investigates activity across several databases on the same host, it may need the database name or another approved identifier. Choose those fields explicitly. Keep full prompts, tool arguments, and results off by default, and enable them for a defined purpose with their own access and retention rules. OpenTelemetry guidance on sensitive data
How to redact the fields you keep
When a record needs the command or output, make a redacted copy of the decoded event before writing anything to the log. Replace the entire value under a known secret field such as api_key. For the remaining fields, walk nested objects and arrays and inspect every string for recognizable credential formats.
The distinction matters in the migration example. A field named api_key tells you what its value is for. A field named command can contain a mix of useful text and credentials. A rule for connection URLs finds the username and password inside that string and replaces that part with a fixed marker. The scheme, hostname, and port stay readable. Keep a database name only if the audit record needs it, and review query parameters before retaining them. OWASP guidance on data to exclude
The redactor can apply both rules in one walk through the event.
redact(value):
if value is an object:
for each field and item in value:
if field is known to hold a secret:
copy[field] = "[REDACTED_SECRET]"
else:
copy[field] = redact(item)
return copy
if value is an array:
return an array of redact(item) for each item in value
if value is a string:
return value with recognized credentials replaced by "[REDACTED_SECRET]"
return valueBuild the command summary and any preview from redacted data. A preview made from the original command has already copied the password, and cutting the string first can split a value before the redactor sees it. Fit the redacted preview on a UTF-8 boundary and count its serialized size, including JSON escaping and record metadata. Apply the same rules to tool results. An error message may echo the input that caused it.
Write or enqueue the record only after redaction. If parsing or redaction fails, keep the event ID and a capture-error indicator and omit the payload. Pattern rules cover the formats they recognize, which is one reason to keep full arguments and output out of the default record.
Give vendors access to the dataset they need
Treat a training export as a new dataset with its own access and retention rules. Build it from approved fields in the redacted records and inspect the actual export before granting access. Give each vendor a separate credential limited to the dataset and the time needed for the work.
Keep track of where older exports went and when each copy is due to expire. The trace and the credential in it can have very different lifetimes. Short-lived credentials limit how long an accidentally retained value can be used. If one is still live when you find it, revoke or rotate it with the issuing service.
Check the record your collector gets
Pick a tool call from a workflow your team actually runs. In a test environment, put a unique fake credential in the arguments and use a destination another engineer can recognize. Read the record as it arrives at the collector. Run the call again with enough output to trigger a preview and inspect that record too.
If the collector forwards events to a SIEM or keeps a separate archive, check those copies too. Change the capture policy while a test batch is queued and check that the next upload follows the current rules. Before sharing a dataset, run the same check on the exported file.
Hand those records to an engineer who wasn't there for the run. Ask them to identify the database the agent targeted. Then search the records for the fake password. Put both checks in the acceptance test for the logging pipeline. Guide to rolling out coding agents · Agentic AI security guide