The Agents Stole the Keys. Then They Paid for More Agents.
Amazon’s threat intelligence team set a trap, and the attackers’ own AI agents walked straight into it. For six weeks, decoy servers posed as popular AI services and recorded the agents’ work and instructions. What emerged is a theft operation that pays for itself: AI agents steal API keys from exposed AI apps, then spend those stolen keys on the computing power to steal more keys.
Amazon cannot verify everything the agents reported about systems its decoys do not watch. But the pattern is consistent across hundreds of targets, and with moderate confidence the team attributes the activity to ARTEX, an open-source AI penetration-testing tool — the same tool the FBI warned about this week.
The loop that funds itself
The campaign works in four steps: agents hunt for AI applications left exposed to the internet. Then they pull the AI provider keys stored inside — the credentials that pay for model access. Next, they verify the keys and add them to a shared pool. Finally, the stolen keys power the models that plan the next round.
The loot is also the fuel: every stolen key buys more model time, which finds more exposed apps, which yields more keys. Amazon’s team put it bluntly: none of the techniques were new — what AI agents change is the speed and persistence of the attacker.

Twelve apps, one shared weakness
The records name a dozen targets with one shared trait: each holds keys for many AI providers in one place, so one weak admin page can expose many accounts — gateways like LiteLLM, One API, New API, Veloera and Sub2API, and app builders like Dify, FastGPT, Langflow, RAGFlow, Open WebUI, LobeChat and Ollama.
The agents carried a playbook of known ways in. LiteLLM’s default master key was on the list, along with unfinished installs an outsider could take over. Langflow’s CVE-2025-3248 — missing authentication that lets a remote attacker run code, added to CISA’s Known Exploited Vulnerabilities catalog in May after ransomware campaigns — is fixed in version 1.3.0. RAGFlow’s CVE-2026-28797 lets any logged-in user run OS commands through template injection, with self-registration on by default. One API had an auth bypass via a request header; the playbook also covered request forgery to reach cloud metadata services and secrets left in JavaScript, source maps, debug routes and environment files.
To find leaked keys, the agents swept scanning services and certificate transparency logs, and searched GitHub, npm and PyPI packages, container layers, notebooks, model-hosting spaces, paste sites and Telegram. Cloud credentials pointed them at managed AI-model services, secret stores and application identities — premium models first.
The Cloudflare case: one token, 400 database dumps an hour
A separate case this week shows what happens when the same tooling gets a different credential. Cloudflare’s responders found ARTEX inside a customer account through a compromised CI/CD API token with no expiry, no IP restrictions and no rate limiting — and broad access across the customer’s cloud setup.
What followed ran at over 69 requests a minute: 400 database dump requests in one hour, new Worker scripts named artex-*, artex-pgrecon-* and artex-do-*, plus persistence attempts and session-token validation for other apps. Cloudflare has not said whether the dumps returned data or the persistence worked. The common root cause across several such investigations, it says, was static CI/CD tokens that never expired.
A second campaign tried to bypass identity checks at two crypto exchanges with deepfakes. One vendor rejected the live deepfake video every time; whether the forged ID photos passed document checks, Amazon did not say.
Why this matters now
The scale is the story: over three days this week, more than 50 families of AI penetration-testing frameworks tried to scan Cloudflare’s customers, and the IPs seen running them now number in the thousands. ARTEX’s developer took the repository down on October 8, but forks, archived copies and a commercial ARTEX PRO keep it available. We have seen a pentest tool go rogue before — what is new is agent frameworks doing it at machine speed, around the clock, with no human between steps.
Amazon notified AWS customers who may have been affected, and recommends treating AI apps, gateways and inference endpoints like any production system: assume exposed secrets will be found fast, and watch for misuse in unexpected spending or unusual usage.
Four checks to run today
1. Kill the defaults. Change LiteLLM’s default master key and every other default admin credential, and finish or remove any half-done install an outsider could take over.
2. Patch the named flaws. Move Langflow to 1.3.0+ and RAGFlow to 0.25.0, which sandboxes templates, and check whether your One API deployment is exposed to the header auth bypass.
3. Give your CI/CD tokens an expiry date. Restrict them to the IPs that should use them and the smallest permissions they need. A token that never expires and works from anywhere was the entry point in the Cloudflare case.
4. Hunt the signs. Look for Cloudflare Workers named artex-*, artex-pgrecon-*, artex-pgw-* or artex-do-*, check logs against the 11 published IPs and the 2,500-plus addresses Cisco Talos links to ARTEX, and treat a sudden AI-spending spike as a breach, not a billing glitch.

The agents invented no new trick. They found doors already open — default passwords, unpatched apps, tokens that never expire — and walked through them thousands of times an hour. Close those doors, and the loop starves.




















One thought on “The Agents Stole the Keys. Then They Paid for More Agents.”