{"slug": "never-let-the-model-see-the-secret-zero-data-retention-is-not-enough", "title": "Never Let the Model See the Secret: Zero Data Retention Is Not Enough", "summary": "Dragos researchers sent nearly 2 million canary prompts carrying unique trackable secrets across about 2,000 routes and found at least three AI providers leaked them, none of which knew until told, according to research published in late November by Dragos Chief Research Officer HD Moore. A couple hundred stolen AWS keys drew tens of thousands of API calls, some within hours of being sent, and one AI lab pulled secret links from roughly two-thirds of prompts flagged Zero Data Retention. The findings show Zero Data Retention guarantees bind only the first hop of a request that can pass through multiple routers and marketplaces, so credentials pasted into a prompt reach every party that touches it.", "body_md": "## TL;DR\n\n- **Nearly 2 million prompts, 2,000 routes, 3 leaking providers:** Dragos sent nearly 2 million canary prompts and traced about 2,000 routes. At least three AI providers leaked secrets, and none knew until told. One lab pulled secret links from roughly two-thirds of the prompts flagged Zero Data Retention.\n- **Tens of thousands of API calls, some within hours:** Stolen AWS keys drew tens of thousands of API calls, some within hours, and attackers confirmed keys with ARTEX. Every employee with an AI assistant is now one paste away from feeding that pipeline.\n- **You only control the first hop** : Rotate anything that may have been pasted, then stop the next one at the laptop. AI Hooks block secrets before a model, router, or reseller ever sees them.\n\nThe moment a credential enters an AI prompt, your attack surface extends to every company involved in processing it. Dragos just proved that for some model providers, guarantees around Zero Data Retention (ZDR) were like writing \"don't mess up\" in the prompt; they were just suggestions that could be ignored.\n\nIn late November, HD Moore, Chief Research Officer at Dragos, [__published research__](https://www.dragos.com/blog/ai-supply-chain-security-canary-tokens?ref=blog.gitguardian.com) on what happened to secrets after they are entered into an AI prompt. For months, his team sent nearly 2 million prompts to widely used AI services, each one carrying a unique, trackable secret. Every secret appeared in exactly one request, so any later use of it pointed straight back to the route that leaked it. Here is what those secrets revealed:\n\n- **About 2,000 routes, at least three breached providers:** The Dragos team traced about 2,000 routes from customer to model and found at least three breached AI providers, none of which knew until the researchers told them.\n- **Tens of thousands of API calls:** A couple hundred stolen AWS keys drew tens of thousands of API calls, some within hours of being sent.\n- **Two-thirds of Zero Data Retention prompts:** One AI lab pulled secret links from roughly two-thirds of the prompts flagged Zero Data Retention.\n\nFor everyone building with AI, this confirms an uncomfortable and simple truth. Once a secret is in a prompt, it belongs to whoever touches that prompt next, and you rarely get to choose who that is.\n\nYou can, however, choose what the LLM can ever see.\n\n## Why Zero Data Retention only covers the first hop\n\nMost of us picture a prompt going from a laptop to one AI company and back. The Dragos research shows a very different trip. Routers forward requests to a pool of models, and in open marketplaces the cheapest seller wins the request. A single request can pass through several routers before it ever reaches a model, and every hop along the way can see the entire prompt and response.\n\nSome of those hops surprised the researchers:\n\n- One router was quietly forwarding traffic to a marketplace it did not disclose.\n- One seller added about 1,000 hidden tokens to every prompt.\n- Several hundred of the traced routes ran through a system nobody could even identify.\n\nAny privacy flags only bound the first hop.\n\n## Stolen secrets are tested within hours\n\nFrom what the researchers could tell, when the secrets were tested, no person was in the loop. Scrapers came back for seeded links two or three days after a request, on a schedule, regardless of which router carried it. Stolen AWS keys were tested within a few hours. On Nov. 1, one attacker confirmed stolen keys with ARTEX, the LLM-driven pentesting framework being used widely by attackers.\n\nMachines move very fast once they have a secret. In one case Microsoft observed, an AI agent went [from scanning GitHub to exfiltrating data from Azure Key Vault](https://blog.gitguardian.com/the-agents-have-now-found-your-secrets-on-github-artex-is-abusing-public-secrets-right-now/) in around five minutes. Campaigns like this run with minimal human intervention, and the agent doing the work costs its operator a few dollars of inference. Roughly 1,400 ARTEX instances were sitting exposed on the internet as of early November, each one ready to put the next stolen key to work.\n\nThe pipeline from leaked secret to working attack is automated end to end. Once your secret is in a prompt, it is part of that pipeline, and no setting on your side will pull it back out.\n\n## Your newest developers never got the memo\n\nFor years, the people writing code were trained developers, focused on quality code and generally adhering to guidelines and governance. They learned, sometimes the hard way, that secrets do not belong in a commit or a chat. In mature organizations, they have pre-commit hooks, code review, and a security team watching the repos.\n\nThings have shifted in the last couple of years, though. Citizen developers are the marketing managers, finance analysts, and operations leads now building tools with AI assistants. They automate reports, wire up internal apps, and connect SaaS tools together, often without ever opening a repository.\n\nTo understand the scale of this shift, you only have to glance at the [__2026 State of the Octoverse__](https://blog.gitguardian.com/github-octoverse-2026/) report: in 2026 GitHub saw 34.3 billion commits, up from 12.9 billion the previous year. That kind of growth is certainly driven by AI, which is allowing anyone to build functional code. We know the Octoverse report is just the tip of the iceberg, as much code from citizen developers never gets checked into shared version control. \n\n### Secrets hop around at an alarming rate\n\nPicture an operations lead trying to get an integration working. They copy the setup page from Confluence into their AI assistant and ask what is wrong. That Confluence page holds the production API key someone pasted there two years ago. Nobody ever told this person that a prompt is a place a secret can leak. There was no reason to think so. It feels like any other tool on the desktop.\n\nThat prompt now joins the automated flow that Dragos traced, through routers and resellers nobody on that team has heard of. The operations lead did nothing malicious and nothing unusual. They used the tool the way it was sold to them.\n\nEven for experienced developers, the temptation to just copy code or config into a prompt is fairly strong; after all, it can debug things extremely fast. Security training hopefully prevents them from actually doing it. Everyone else in your org with a coding assistant never got traditional secrets training, and they are connecting their new tools into real systems and real data.\n\n### Control the one hop you own\n\nEvery hop after the laptop belongs to someone else. You can choose providers carefully, read the contracts, and set every privacy flag available, and Dragos has shown how far that gets you in some cases. Those are promises, and promises are only as good as the systems behind them.\n\nThe first hop is different. The prompt starts on a machine your organization owns, typed by a person you employ. That is the one point in the whole chain where you can put a control that does not depend on anyone else keeping their word.\n\nIt is not the only hop you own, though; any data flowing from your machine or into your machine is another chance to scrutinize the contents and ensure that secrets didn't get copied in from another tool, an old Confluence page, a Jira ticket, or anywhere else secrets end up across the credential layer.\n\nIf the secret never leaves the laptop, nobody downstream can lose it. If no secrets ever make it to the LLM, we're all a little safer.\n\n## If you think you are exposed, rotate\n\nThere is only one real answer for a secret that may have gone into a prompt. Rotate it.\n\n### What does not work\n\nThese do nothing for a copy that is already sitting in a reseller's request log or an attacker's toolkit:\n\n- Deleting the chat\n- Turning on ZDR after the fact\n- Asking a provider to purge its logs\n\n### What to do instead\n\n1. **Start with your logs.** Review your cloud and AI provider logs, and any prompt or session logs your teams keep, to see whether credentials appear there. If a credential shows up, treat it as stolen and rotate it.\n2. **Then look at the developer machines themselves.** Shell history, AI assistant transcripts, and local .env files show what was available to copy and paste into an assistant. Those are the files a developer or a citizen developer reaches for when an AI tool asks for more context. Knowing what sits on those machines tells you which credentials could have ended up in a prompt, and that is the list you need to rotate.\n\nFortunately, you do not have to do that inventory by hand.\n\n## Remediate and prevent secrets loss across the whole organization\n\nThe strongest programs work in three moves:\n\n- **Prevent:** Stop secrets at the prompt\n- **Detect:** Find the ones already at risk sitting on developer machines\n- **Remediate:** Rotate any risky ones that still work\n\n### Prevent the secret from ever entering the LLM\n\nThe safest secret is the one the model never sees. GitGuardian [__AI Hooks put ggshield guardrails inside the AI coding__](https://blog.gitguardian.com/ai-hooks-ai-coding-assistants/) assistants people already use, like Claude Code, Cursor, and Codex. When someone hits enter on a prompt, the hook scans it on the laptop and blocks it if a secret is inside. That Confluence page with the production key never reaches a model, a router, or a reseller.\n\nThe hook watches what the agent does on its own, too. Before an agent reads a file, runs a shell command, or calls a Model Context Protocol (MCP) server, the hook checks it for secrets. All of it runs on your machines, under your control, with no promise from anyone else required.\n\nThat is what real control looks like. Not suggestions. Deterministic checks at runtime, away from the LLM.\n\n### Detect the secrets already sitting on developer laptops\n\nPrevention will never catch everything that happened before the hooks went in. [__Developer Endpoint Protection__](https://www.gitguardian.com/developer-endpoint-protection?ref=blog.gitguardian.com) scans developer machines for the credentials sitting in shell history, agent transcripts, and MCP configs.\n\nIt gives you a unified, centralized view of what could have been pasted into an assistant, for traditional developers and citizen developers alike. That list is exactly what you need when deciding what to rotate after a story like this one.\n\nGetting there is easier than most teams expect. Endpoint protection deploys through the mobile device management (MDM) tools you already run, like Intune, Jamf, and Kandji, so it reaches every managed laptop on a schedule. Once installed, a single ggshield machine setup command configures the [__AI Hooks__](https://docs.gitguardian.com/ggshield-docs/integrations/ai-coding-tools/secret-scanning-for-ai-coding-tools?ref=blog.gitguardian.com#how-it-works) and the rest of ggshield's protections on any machine.\n\nThat means every machine can get the same protections. From the developer laptop and the desktop under someone's desk to that weird Linux box in the corner running a single microservice, every one of them becomes auditable, and all their plaintext secrets become searchable.\n\nOnce you find them, the real work begins in rotating them.\n\n### Remediate exposure by rotating any keys that allow real access\n\nThe [__GitGuardian Platform__](https://www.gitguardian.com/platform?ref=blog.gitguardian.com) shows which credentials still matter. Validity checks tell you which keys still authenticate today, and presence checks confirm whether a known copy still sits in a repo, a SaaS tool, or a developer laptop. When deployed across your whole organization, the platform shows everywhere else that same credential lives, including the Jira ticket or config file it got copied into, and also where it is supposed to live, in your vaults.\n\nYou need to know who owns the key and what depends on it before you rotate. Commit attribution, source metadata, and ownership suggestions connect each incident to the person who actually has to act. The Exploration Map shows which systems consume a credential, what resources it can reach, and which secrets managers hold it.\n\nRisk scores pull that context together, weighing privilege scope and access to sensitive systems. From there, the work flows through the tools your teams already use. Assignments land in Jira or ServiceNow with enough context that the engineer doing the rotation does not have to repeat the investigation.\n\nGitGuardian's [__rotation checklist__](https://blog.gitguardian.com/service-account-credential-rotation-checklist) walks through swapping credentials without breaking production. Closing the incident rests on evidence. A validity recheck confirms the old key is dead, and the Closed but valid view catches any incident marked done while its credential still works. \n\nWe have helped many organizations streamline their remediation plans and mature their secrets management programs. We are proud to have helped those same teams prevent the issue before it became a backlog of tickets, which is something you can implement right now for future pasted secrets.\n\n## Install AI Hooks today\n\nH.D. Moore's strongest recommendation is to run your own model. When the model lives on servers you own, the prompt stays inside your own infrastructure from the moment someone hits enter to the moment the answer comes back.\n\nEvery hop belongs to you, from the network to the logs, and you decide who can see any of it. This is effective, but cost-prohibitive for most teams.\n\nThe next best move is going directly to a first-tier provider, where there is \"one company, one contract, and one privacy policy to read.\" Even this carries no real guarantees in a world of acquisitions and frequent updates to terms of service.\n\nBut even a model you host yourself writes prompts into logs your team now has to protect. The one thing fully in your hands is the prompt itself, on the laptops your developers and citizen developers use every day.\n\nThat is why the first move, wherever your prompts connect to, is installing [__AI Hooks__](https://docs.gitguardian.com/endpoint-protection/ai-hooks?ref=blog.gitguardian.com). Put them on your own machine today, even before you roll them out to anyone else. It takes just a few seconds and a few commands, and from that moment on, the secrets you paste by accident never reach a model, yours or anyone else's.\n\nWhen you are ready to protect every laptop in the organization, we are happy to talk about rolling out endpoint protection through your MDM and securing your credential layer together.\n\n## FAQ\n\n## What is Zero Data Retention (ZDR) in AI?\n\nDragos describes ZDR as the strictest privacy setting, under which prompts and responses are not stored. Customers can set the flag per account, per API key, or per request.\n\n## Does Zero Data Retention guarantee my prompts are not stored?\n\nNo. Dragos found that a privacy flag only binds the first hop. One AI lab's systems fetched secret links from roughly two-thirds of the requests marked ZDR.\n\n## What did the Dragos canary prompt study find?\n\nFrom July through November 2026, the team sent nearly two million prompts, each carrying a trackable secret. At least three hosting providers turned out to be breached, and none knew until the researchers notified them. Attackers made tens of thousands of AWS API calls with a couple hundred stolen keys, in some cases within hours.\n\n## What should I do if a secret was pasted into an AI prompt?\n\nRotate it. Deleting the chat, turning on ZDR afterward, or asking a provider to purge logs does nothing for a copy already sitting in a reseller's log. Review cloud, AI provider, and session logs, then check shell history, assistant transcripts, and local .env files to list what else needs rotating.\n\n## Do I need a dedicated tool for AI prompt security?\n\nEnabling secret filtering is one of Dragos's five recommendations. GitGuardian AI Hooks scan prompts before the model receives them, and check commands, file reads, and MCP calls before they run.", "url": "https://wpnews.pro/news/never-let-the-model-see-the-secret-zero-data-retention-is-not-enough", "canonical_source": "https://blog.gitguardian.com/zero-data-retention-ai-prompts/", "published_at": "2026-11-25 13:19:23+00:00", "updated_at": "2026-11-25 13:41:47.899172+00:00", "lang": "en", "topics": ["ai-safety", "ai-policy", "large-language-models", "ai-agents"], "entities": ["Dragos", "HD Moore", "AWS", "ARTEX", "Microsoft", "Azure Key Vault", "GitHub"], "also_reported_by": [], "takeaway": "Zero Data Retention flags only bind the first hop: in Dragos's test of nearly 2 million canary prompts, one lab still pulled secret links from roughly two-thirds of ZDR-flagged prompts, and stolen AWS keys drew tens of thousands of API calls within hours.", "recommendation": {"advice": "Block credentials at the laptop before they reach any model, router or reseller, and rotate any secret that may have been pasted into a prompt, since Dragos saw stolen AWS keys tested within hours.", "playbook": "agent-security", "playbook_url": "https://wpnews.pro/playbooks/agent-security"}, "alternates": {"html": "https://wpnews.pro/news/never-let-the-model-see-the-secret-zero-data-retention-is-not-enough", "markdown": "https://wpnews.pro/news/never-let-the-model-see-the-secret-zero-data-retention-is-not-enough.md", "text": "https://wpnews.pro/news/never-let-the-model-see-the-secret-zero-data-retention-is-not-enough.txt", "jsonld": "https://wpnews.pro/news/never-let-the-model-see-the-secret-zero-data-retention-is-not-enough.jsonld"}}