剖析 Together AI 提示詞外洩事件:AI 編碼智能體提交憑證
An AI Coding Agent Committed the Keys: Inside Together AI's Prompt Leak
開發 Together AI 公開 GitHub 儲存庫 xorl 時,一個 AI 編碼智能體提交了可存取私人 Hugging Face 儲存庫的憑證,未經授權者據此下載提示詞樣本。
On November 21, 2026, Together AI published a security disclosure with an uncomfortable root cause: an AI coding agent leaked the credential that exposed months of customer prompts.
Not a phishing email. Not a misconfigured bucket left open by a tired engineer at 2 a.m. An AI coding agent, working on the company's public GitHub repository, committed a credential that unlocked a private repository full of prompt samples. Someone grabbed it before the commit was reverted — and downloaded the lot.
What actually leaked
As part of routine software testing, Together AI collected prompt samples — authorized for that use — and stored them in a private Hugging Face repository. The samples came from requests to three models on its serverless inference service: MiniMax M3, GLM-5.2, and Kimi K2.6, primarily from June 24, July 4, July 8, and July 14, 2026.
During development of the company's public GitHub repository, xorl, an AI coding agent committed a credential that provided access to that private Hugging Face repository. Together AI says its automated scanning detected the exposed credential and reverted the commit. But the exposure window was long enough: during it, an unauthorized party obtained the credential and used it to download the stored prompt samples.
What happened next is the part that should worry anyone running inference infrastructure. The party didn't just take the prompts and leave. It searched the samples for credentials to other services — and tested whether those credentials were valid. Five of the credentials it tested turned out to be canary credentials planted as part of a Dragos security experiment: tripwires designed to reveal exactly this kind of unauthorized access. The canaries did their job. Whether the party found any real credentials among the samples is still under review.
Together AI says it has no reason to believe the unauthorized party leaked the data further, and understands the data has now been deleted. It is working with an external forensic investigation firm and law enforcement, and says it has found no evidence of additional prompt leakage beyond this incident. Its review of the affected prompt contents is ongoing, to determine whether sensitive personal information or other customer data was exposed, and it says it will contact affected customers directly.
The four fixes — and which one matters most
The company lists four changes it made after the incident:
- Scoped or short-lived credentials, and keyless access where supported, to limit the blast radius of any future exposure.
- Checking all pull requests for credentials.
- Making zero data retention (ZDR) the default setting for new accounts.
- Updating its development processes governing the use of AI coding agents.
All four are sensible. But the third is the one with the widest consequence. Until now, ZDR was opt-in: customers handling sensitive prompt data had to go into account settings and turn it on. From now on it is the default for new accounts — which is an admission that the old default was wrong. A service that stores prompt samples for testing should never have had retention on by default for customers who never asked for it.
The fourth fix is the one that names the actual failure. The credential didn't leak because someone pasted a secret into a public repo by hand. It leaked because an autonomous agent, given enough access to do useful work, did something a careful human wouldn't — and nobody's review caught it before it shipped. Together AI's own scanner caught the exposure and reverted the commit, but detection after the fact is not prevention. The lesson for every team shipping agent-written code: your agent's commits need the same credential scanning, the same review gates, and arguably stricter ones than a human's, because an agent will commit a secret with the same confidence it commits a bug fix.
What this means if you build with agents
Three takeaways, in order of how much control you actually have:
Turn on zero data retention wherever it exists. Together AI's own advice to customers is to enable ZDR in account settings. That advice applies to every inference provider you use, not just this one. If a provider stores your prompts by default and offers a retention-off switch, the switch should have been on from day one. Go check yours now — not after the next disclosure.
Treat agent commits as untrusted input. The xorl incident is the first high-profile case of an AI coding agent leaking a credential into a public repo, and it will not be the last. If your agents can commit, they can commit secrets. Secret scanning on every pull request — which Together AI now does — should have been there before the agent was given write access, not after.
Assume your prompts are someone else's training and testing data until proven otherwise. The samples in this incident were collected for "routine software testing" with authorization. That is a legitimate use. But it means the prompts you send to a hosted inference API may be copied, stored, and sampled in ways your mental model of "I sent a request and got a response" doesn't capture. The only reliable way to be sure a prompt doesn't persist is a retention policy you can verify — which is exactly what ZDR is for.
The irony is hard to miss: the same week the industry celebrates agents that can write code, fix bugs, and run entire software factories, one of those agents quietly committed a credential to a public repository and exposed months of customer prompts. The agents are getting more capable faster than our guardrails for them are. Until the guardrails catch up, the cheapest protection is the oldest one: don't let anyone — human or agent — keep a copy of your data unless you asked them to.
Source: Together AI, "Security event: Prompt leakage for requests in June and July of 2026" (together.ai/blog, November 21, 2026). The investigation is ongoing; the scope described here reflects the disclosure as published.
來源:DEV Community · dev.to