
UpTrajectory Review
Security researchers at Apiiro scanned GitHub and found 1,122 public files containing passwords and secrets leaked by Claude Code, Anthropic's command-line coding agent. The culprit sits in a deceptively small feature: when the tool asks for confirmation before it runs a command, it offers a 'don't ask again' option. Users who select that option can inadvertently store their approval in a local settings file, and that file can end up committed to a public repository. The research landed on Hacker News with 131 points and a heated comment thread, which tells you the developer community feels the sting of recognition.
If you run a small shop and your developers use AI coding assistants, this is your problem, not a big-tech footnote. A leaked password in a public GitHub file is an open door to your cloud bill, your customer data, and your source code. Small teams rarely have a dedicated security engineer scanning every commit, and a single hurried 'don't ask again' click during a late-night deploy can undo months of careful access control. The blast radius extends beyond your own repo: contractors, agencies, and anyone who clones your code inherits the exposure.
What strikes us as genuinely new here is the mechanism, not the outcome. Secret leaks through committed .env files are old news; a vendor's convenience feature quietly writing credentials to disk is a fresh and troubling pattern. The Hacker News discussion shows real disagreement over where responsibility lies. Anthropic defenders argue users should review what they commit; critics counter that a tool designed to accelerate work should not bury a credential write inside a routine prompt. We side with the critics: security defaults matter, and 'don't ask again' should never mean 'store this in plaintext.'
The second-order effect reaches every AI agent that touches a filesystem. As coding assistants gain autonomy, they will handle tokens, keys, and session cookies more often, and each interaction creates a new leak path. Teams that adopted AI tools to move faster now face a slower, more cautious workflow: audit what the agent writes, scrub commits, and rotate credentials on a schedule. That friction is real, and it falls hardest on small businesses that adopted these tools precisely because they lacked the staff for heavy process.
Watch for Anthropic's response: whether it changes the default, encrypts stored approvals, or warns users before any file write. In the meantime, run a scan of your own repositories for exposed secrets, rotate any credential that an AI agent has touched, and disable 'don't ask again' for commands that handle authentication. Treat every AI-generated file as untrusted input until you have read it. The speed gain from a coding agent evaporates the moment you spend a week cleaning up a breach.
This incident also resets the compliance conversation. If you handle customer data under GDPR, HIPAA, or PCI rules, an AI tool that can leak secrets into public code is a reportable risk, not a productivity perk. Document which agents your team uses, what permissions they hold, and how you audit their output. A one-page policy today saves a regulatory headache tomorrow.
Takeaway: Audit your repositories for AI-agent leaks now, rotate exposed credentials, and disable 'don't ask again' for any command that touches authentication.
Excerpt from the original — Hacker News (front page)
Article URL: https://apiiro.com/blog/coding-agents-leaking-secrets-github-dont-ask-again
Comments URL: https://news.ycombinator.com/item?id=50407882
Points: 131
# Comments: 96