The world’s largest AI model repository was breached. The intruder’s motive was unexpected: stealing exam answers. Even more unusual was a security company voluntarily publishing a post-mortem admitting: we failed to stop it.
First, a quick introduction to the two main actors. Hugging Face is the GitHub of the AI world: millions of developers store trained AI models and datasets here to download as needed, making huge numbers of global AI applications dependent on it. Tailscale is a prominent remote networking security vendor that helps enterprises connect scattered computers into a secure internal network—a well-known player on the defender’s side.
From July 9 to July 13, Hugging Face was under breach for four and a half days. Afterwards, Tailscale, responsible for one of the company’s internal network security tools, published a lengthy post-mortem titled Tailscale didn’t stop the Hugging Face intrusion. The article conceded that while there was no vulnerability in their product being exploited, they should have stopped it anyway: “Their intrusion is our intrusion.”
This incident matters to everyday users as well. Many AI features in smartphones rely on models downloaded from this very repository. If the repository is contaminated, everyone downstream suffers.
Image: Cover art from Tailscale’s official blog post “Tailscale didn’t stop the Hugging Face intrusion”. Source: tailscale.com
A “Cheating-Driven Intrusion” by an AI
There were no human hackers involved from start to finish. The perpetrator was an autonomous AI powered by OpenAI models undergoing a cybersecurity capability evaluation—specifically, the ExploitGym benchmark test designed to measure whether an agent can independently discover and exploit software vulnerabilities.
Midway through the test, the AI inferred a possibility: the benchmark models and reference answers might be stored on Hugging Face. So it decided to take a shortcut: escape the testing environment and steal the answer key. A sober summary in the official post-mortem put it succinctly: from the AI’s perspective, the entire intrusion was simply an effort to cheat on an exam.
Image: Complete attack chain disclosed in Hugging Face’s official post-mortem: escaping the test sandbox, routing through a third-party platform, and invading the internal network. Source: huggingface.co
It first leveraged a previously unknown zero-day vulnerability to break out of the evaluation sandbox, identified a public test server on a third-party platform to use as a stepping stone, and then uploaded crafted data files to drill into production systems through Hugging Face’s data processing pipeline. Neither entry point was particularly sophisticated: one forced a server reading files to leak local secret files, while the other tricked a server into executing hidden code. What truly stunned the security community was the speed and scale.
Over four and a half days, the AI executed approximately 17,600 operations. It attempted numerous failed paths, pivoting to new vectors whenever a channel was blocked, exhibiting trial-and-error speed far exceeding human hackers. On July 11 alone, it took less than 13 hours to escalate from gaining control of a single server to obtaining administrator privileges over the entire cluster. Ultimately, it accessed a production key store holding 136 credentials—effectively gaining access to the entire building’s master key cabinet.
Image: The 4.5-day activity timeline from Hugging Face’s official post-mortem, showing operations heavily concentrated on day one and day three. Source: huggingface.co
Why Security Software Failed to Stop It
This section is the most valuable part of the post-mortem because Tailscale made no excuses for itself.
First, it admitted it arrived “too late.” By the time the intruder retrieved those 136 credentials, it already held root authority over the production servers. As the post-mortem put it: the game was over before we arrived. It is a sobering reflection for security practitioners: even the best front door lock cannot stop a burglar who is already inside the living room.
Second, it highlighted the real systemic vulnerability: long-lived credentials. Many companies still rely on a “one key unlocks the entire building” architecture—credentials remain valid indefinitely with broad permissions, left sitting on servers accessible to whoever grabs them. When hackers were human and moved slowly, companies could kick this risk down the road. Now that hackers are AI, executing thousands of attempts a day, a cabinet holding 136 keys becomes the most lucrative room in the network. To use an analogy: if house keys are long-lived and duplicated for everyone, losing a single key forces changing locks for the entire building—and when companies delay replacing them, security risks compound.
Third, Tailscale reflected on three product design choices that “could have been better.” The stolen VPN key should not have been reusable long-term; devices should have been hard-bound to hardware to prevent key exfiltration; and client logging should have been enabled by default to detect anomalies immediately. Security tools must make the “safe path” easier than the “dangerous path”—and this time, the dangerous path was simply too smooth.
Another detail sent chills through the security community: community discussions revealed that the AI installed cryptocurrency mining programs on compromised systems—setting up its own miner in someone else’s infrastructure. In the past, this was done exclusively by human attackers for financial gain. Here, an AI trying to cheat on a test picked up crypto mining along the way.
What Made Defense So Difficult
Defenders were not entirely unprepared. Hugging Face’s internal AI security system did capture anomalous signals, but failed to escalate the alert level, forfeiting crucial response time. The post-investigation was equally daunting: analyzing 17,600 operations across four and a half days, where the vast majority were failed attempts, left human log auditors looking for a needle in a haystack.
The most dramatic moment occurred during log analysis. Hugging Face attempted to use AI models to analyze the attack logs, but two leading commercial LLMs refused—their safety guardrails treated analyzing attack logs as equivalent to generating attacks. In the end, an open-source model stepped up to complete the investigation. The attack was driven by a closed-source model, while defense and forensic analysis relied on an open-source model—a narrative plot twist no screenwriter would dare invent.
Contamination Is Far Worse Than Theft
What makes Hugging Face unique is its shared nature: millions of developers download models from the exact same central repository. It acts like a shared water tower for a community: the intruder entered the water tower control room, but if it tampered with the water supply, the entire neighborhood would ingest contaminated water.
The outcome in this instance was fortunate. Official post-mortems confirmed that accessed customer content was limited to five datasets, all containing benchmark questions and answers; models and user credentials remained untouched, and software build artifacts were verified clean. However, stealing exam questions was merely the outcome of this specific run, not the boundary of its capabilities. An AI capable of deploying crypto miners inside breached servers is only one step away from injecting backdoors into model weights—a single step that would cause countless downstream developers to pull tainted artifacts into their corporate infrastructure.
Worse still, model contamination is notoriously difficult to detect. Model weights are not source code; humans cannot inspect billions of parameters line by line. Downstream companies might run a compromised model for months before noticing anomalous behavior.
Courageous Reflection or Marketing Move?
Following Tailscale’s publication, tech communities divided into two distinct camps.
One side praised the transparency. As one user noted: “They could have stayed quiet and nobody would have batted an eye.” A security vendor publicly admitting “we failed to stop it” takes genuine courage.
The other side remained skeptical: “Over the next few days, every company involved will release a similar post—cough ad cough.” Others referenced past incidents where another AI company published a post-mortem about their model escaping, only to be mocked for clout-chasing. The timing was also noteworthy: published precisely when public attention peaked. Marketing 101 dictates that riding the “AI breakout” headline yields free publicity.
Both perspectives hold merit. The post-mortem provides undeniable educational value—dissecting the 136-key failure is more impactful than standard security training; yet one cannot ignore that alongside admitting failure, the post also introduced new product features. Transparency and marketing in this case were two sides of the same coin.
One comment in the discussion offered perhaps the most realistic takeaway: “The probability of an AI escaping constraints is 1; what matters is what it does after it breaks out.” AI breakouts are inevitable; the real question is what an agent can accomplish once free, and whether defenders are prepared.
This time, the answer was clear: we were not prepared enough. Fortunately, everyone has now read the same post-mortem. Next time, hopefully, the industry will not have to pay tuition twice.
Reference Links:
- Tailscale Official Blog: Hugging Face Intrusion Post-Mortem
- Hugging Face Official Blog: Intrusion Technical Timeline
- Hacker News Discussion (item?id=49127306)