For small firms
A leaked key is
already a compromised key
If an API key or app secret ends up in a public repository, assume someone else already has it. Microsoft's write-up of an agentic scanning tool called ARTEX shows how fast that can turn into a real break-in, and what to do first.
For years, people have hunted public GitHub repositories for credentials left in config files, scripts and sample code. That used to take time: find a repo, read it, try the key, move on.
On 5 November 2026, Microsoft Threat Intelligence described threat actors using an agentic AI offensive framework, including a tool called ARTEX, to search public GitHub for exposed secrets. Those secrets included credentials, application credentials and AI inference-related API keys across multiple applications and cloud services. The agents then helped analyse what they found and drive follow-on attacks, cutting down the need for a person to sit at the keyboard through every step.
In at least one case Microsoft observed, an AI agent went from scanning GitHub for secrets to exfiltrating data from Azure Key Vault in five minutes.
That is the useful number for a small firm. Not "AI is magic". Five minutes from a public secret to pulling data out of a vault.
What happened after the secret was found
Microsoft also investigated follow-on activity that misused valid application credentials. From 28 October 2026 they saw successful service principal sign-ins involving multiple application IDs across some affected customers, including cases where a multitenant application credential was compromised at the source and then used to reach downstream tenants.
Once inside, the activity Microsoft describes includes cloud resource discovery and credential and data exfiltration, including from Azure Key Vaults and Storage Accounts, plus abuse of Azure AI services. Compromised applications were also seen accessing SharePoint and OneDrive in targeted tenants, and in some tenants sending Microsoft Graph API requests that searched for content of interest.
You do not need to run on Azure for the lesson to land. The pattern is ordinary: a long-lived secret sits in a public place, an automated hunt finds it, and whatever that secret can reach is treated as open.
Delete the commit. Then rotate the key. Then check what it could reach.
Microsoft's advice is blunt, and it matches what any UK small business should do when a key leaks:
- Scan your code on GitHub and find where secrets are present.
- Remove the secrets from the codebase.
- Immediately rotate any exposed keys or credentials.
- Treat publicly exposed credentials as compromised even if the original disclosure has since been edited or deleted. Removing the content does not invalidate the credential, and it does not clear copies in edit history, caches, archives, logs or other systems.
- Investigate how the credential was used historically.
In other words: scrubbing the file is not enough. A key that was public remains usable until it is revoked or rotated. Adding a line to .gitignore after the fact does not untrack a file that was already committed, and it does not cancel a key that has already been copied.
Microsoft also points organisations at GitHub's own secret scanning (including public monitoring beyond the repos you own) and at reducing reliance on long-lived client secrets where managed identities or similar options exist. Those are sensible for firms already on that stack. The first move for everyone else is still the same: rotate what leaked, then work out what that key could open.
Why this matters for a UK small firm
Most small firms are not running a Security Operations Centre. They are connecting AI tools, CRMs, mail and cloud storage with API keys and OAuth apps because that is how the products are sold.
If one of those keys lands in a public repo (a personal fork, a "temporary" gist, a sample project, a laptop that pushed the wrong folder), the clock Microsoft describes is the one that matters. You do not get a polite email first. You get whatever the key can do: list storage, read a vault, call an AI API on your bill, open mail or files the app was allowed to reach.
That is why the boring hygiene beats the drama:
- Prefer short-lived credentials and the vendor's recommended auth where you can.
- Never put live keys in source that might be pushed.
- If a key was exposed, rotate it first, then clean the history, then review access logs for that identity.
- Keep a list of which apps and keys exist, who owns them, and how you revoke them on a Tuesday afternoon.
None of that makes you "secure". It means you treat a leaked key as already stolen, which is what Microsoft is telling larger organisations to do as well.
A free check for exposed AI keys
If you want a quick look at whether AI provider keys are sitting in a public GitHub repository, we have a free browser check: Are there AI keys in your public repo? Paste a public repo URL. It looks for common AI key patterns. No sign-in, and we keep no record of what you checked.
It will not replace a proper secret scan of your whole estate, and a clean result does not mean every credential is safe. It is a fast way to answer one narrow question before you connect the next tool.
If an agent can already act with those keys, the companion questions are still worth asking: Who approves before a tool runs? and, further back, Can you stop your AI agent? A leaked key is one failure mode. An agent that can use a key without a clear gate is another.
Where to start
- Run the AI-key check against any public repos your firm (or your contractors) still have open.
- If anything shows up, rotate that key before you do anything else, then remove it from the code and check history.
- Write down which AI and cloud credentials you actually use, and how you would revoke them in five minutes.
The rest of our free checks live on the tools page. Answer honestly. The finding that makes you rotate a key today is the useful one.
Free check, the check in this post
Are there AI keys in your public repo? Paste a link, get a report.
Free. Runs in your browser. We keep no record of what you checked.