Cloud hosting platform Railway disclosed a 26-hour security breach last month that resulted in roughly $740,000 in fraudulent charges across multiple AI providers, after attackers used safety-stripped language models and an automated hacking framework to steal customer API credentials at speed.
Railway published its full post-mortem on November 10, detailing how a zero-day vulnerability in its build infrastructure allowed attackers to chain together a series of internal misconfigurations and ultimately reach encrypted environment variables tied to customer workloads. The company said up to 1.85 percent of its workspaces, roughly 100,000 accounts, could have had their stored secrets decrypted.
The Attack Unfolded Over 26 Hours
The intrusion began October 20 at 07:28 UTC, when an attacker exploited a previously unknown flaw in Railway's build system that allowed them to partially escape filesystem isolation and read files on host virtual machines. Those files contained a credential that build servers used to authenticate to internal services.
The attacker initially hit dead ends testing that credential across Railway's systems, but eventually found it granted access to Temporal, the company's internal task management platform. Inside Temporal was a copy of Railway's internal codebase sitting behind an incorrectly configured OpenID Connect authentication mechanism, which let the attacker obtain temporary cloud credentials and move deeper into the company's infrastructure.
By 13:58 UTC that same day, Railway engineers had spotted unusual registry API calls and replaced the stolen credential. The attacker had already read enough of the codebase to identify another path forward.
At 03:26 UTC on October 21, the attacker used the misconfigured OpenID Connect setup to obtain a short-lived cloud credential, then pulled additional internal credentials including an SSH private key. This gave them access to a machine that coordinates customer workloads, which could reach Railway's production database and held decryption keys for stored environment variables. The attacker ran targeted queries searching specifically for AI provider key names. By October 22, Railway had revoked credentials, rebuilt affected infrastructure, and restored builds for all users.
AI Agents Ran the Attack
What made the intrusion stand out was not just what was stolen, but how. Railway's post-mortem says the attacker ran AI agents built on safety-removed models through a framework comparable to ARTEX. The stolen Railway codebase gave those agents enough context to test multiple attack paths simultaneously.
Railway described the response as "a contest of agent speed," with engineers hardening systems while the attacker's automated tools probed for new weaknesses in parallel. Cybersecurity firm Wiz, which assisted with the investigation, attributed the attacker's tooling to what are known as abliterated models, language models that have had their content restrictions deliberately stripped out.
Who Owes What
The $740,000 in charges was split across several AI providers. AWS Bedrock and Google Gemini have begun processing refunds under their existing fraud policies. OpenAI and SpaceXSI are reviewing claims through a shared channel with Railway. Anthropic has not yet issued a refund, and Railway says it will cover those costs while negotiations continue. OpenRouter has invoked a no-refund policy, leaving Railway to absorb that portion of the losses as well.
Railway had initially told customers on October 26 that it could not reimburse spending made with compromised keys. Its November 10 post-mortem reversed that position, committing the company to covering charges that providers refuse to refund.
Part of a Larger Pattern
Railway's breach is not an isolated incident. OpenCode, Warp, and Fireworks AI all disclosed similar credential thefts between October 6 and 23. Fireworks AI then reported a second breach at a third-party cloud provider on October 24, which subsequently affected Notion, which uses Fireworks to power its AI features. Fewer than one percent of Notion workspaces may have been exposed.
Security firm Sysdig, which tracks this category of attack under the term LLMjacking, has documented how the costs can pile up fast. Its research found that stolen Claude 3 Opus credentials alone can generate more than $100,000 in charges in a single day. LLM-related API requests tracked by Sysdig rose tenfold in July 2024, and the number of unique attacking IP addresses doubled in the first half of that year.
Railway filed a complaint with the FBI's Internet Crime Complaint Center and believes the stolen keys were passed to what it describes as distributed transfer stations, services that resell or relay AI access, possibly to support model distillation projects.
Customers who had workloads on Railway during the breach window are advised to rotate all API keys and stored environment variables, review AI provider usage logs for anomalous activity, and report unauthorized charges to their respective providers.