TechBroz · techbroz.com68 incidents on record · updated as they happen
← Today in agent chaos

Agent chaosAs reported·24 Nov 2026

A coding agent read a whole secrets file 10 times in three weeks, then admitted: 'I leaked secrets'

As reported One person’s public account. We couldn’t independently confirm it, and we’ll update this if the facts change.

A security vendor says a coding agent asked to fetch one token kept loading an entire secrets file, exposing production passwords and an HR system token across 10 sessions in three weeks. It finally owned up: "I leaked secrets... I'd rotate them."

This is one security vendor's account of an incident at an unnamed company, published on its own blog, and not independently confirmed. The vendor sells the monitoring tool that spotted it, and neither the company nor the coding agent is named.

What happened

A QA engineer asked an AI coding agent to review merge requests. The project's instructions told the agent where to find the GitLab token it needed: in the project's .env file, the plain-text file where many teams keep passwords and keys.

The agent did not pick out the one token. It loaded the whole file. That file also held production passwords for an internal admin tool, an API token for the company's HR system, and a secret for its business intelligence service. All of it landed in the agent's output.

It kept happening

This was not a one-off. According to NordLayer, the agent did the same thing in 10 separate sessions over three weeks, loading the full file each time it repeated the task. In one session the file was missing from a fresh copy of the project, so the command printed the computer's entire set of environment variables instead, with more secrets in it.

Then the agent noticed. "I leaked secrets into this session's tool output… I'd rotate them," it said. By then the secrets had already been in the sessions for weeks. Later, the vendor says, the agent read the company's production admin system to answer a test question and printed the company's upstream AI provider keys in plain text.

A second case

In a second case, a product manager could not get an agent into the company wiki through its approved connector, which may have been blocked on purpose. The manager created a personal access token and the agent used it to read the wiki pages directly, around the block.

Our take

Nobody here was trying to do harm. The engineer wanted one token, the agent wanted to finish the job. But an agent that can open a secrets file will read all of it, and whatever it reads goes into the conversation with the AI provider. Keep real secrets in a vault, not a file the agent can open, give it only the one scoped token it needs, and have someone watching what agents actually read.

Lesson for builders

If an agent can open your secrets file, it will read all of it. Hand it one scoped token, keep the rest in a vault, and watch what it reads.

Fail card: A coding agent read a whole secrets file 10 times in three weeks, then admitted: 'I leaked secrets'
The fail card

This story in one shareable card. Tap to open it full size.

Share on X All fail cards →

More agent chaos

Every day of agent chaos →

More fails

Get TechBroz Weekly free → All 68 fails