The Hugging Face Breach Is the Best Argument for On-Prem AI You’ll Read This Year

By Ali Hayat is CEO of Axipro [ Join Cybersecurity Insiders ]
19

In July, one of OpenAI’s models escaped a test sandbox, found a zero-day in third-party software OpenAI was hosting internally, got onto the open internet, and spent a weekend inside Hugging Face’s production infrastructure. Hugging Face later reconstructed more than 17,000 recorded events. Nobody at OpenAI broke a rule. The safeguards were switched off on purpose, for an evaluation, and the model did exactly what it was told to do. It just did it in someone else’s building.

That part of the story has been covered everywhere. The part that matters for anyone running a business in the Gulf, the UK, or the EU is what happened next, and almost nobody is talking about it.

The victim couldn’t investigate its own breach with the tools it sells

Hugging Face’s post-mortem contains one paragraph that should be pinned to the wall of every compliance team. When they started analyzing the logs, they first tried the frontier models behind commercial APIs. The analysis required submitting real attack commands, exploit payloads, and command-and-control artifacts. The providers’ safety guardrails blocked the requests. The guardrails couldn’t tell an incident responder from an attacker.

So Hugging Face ran the forensics on GLM 5.2, an open-weight model, on its own infrastructure. Their words on the outcome: no attacker data, and none of the credentials that data referenced, left their environment.

Read that twice. A company whose entire business is hosting AI models had to fall back to a locally hosted model to investigate a breach caused by a US frontier lab, because the US frontier labs’ APIs wouldn’t help. And the fallback was better, not worse, from a data protection standpoint.

Important: Hugging Face only got to that second, safer option after trying the first one. Several security practitioners pointed out on Hacker News that attack logs referencing live credentials had already been submitted to external APIs before the switch. In a regulated environment, that first attempt is a reportable event in its own right. The lesson isn’t that they eventually got it right. It’s that the safe path has to be the default before the incident, not a discovery during it.

Where this lands for GCC, UK, and EU companies

Hugging Face is a US company with US infrastructure. It had the luxury of treating the API question as a capability problem. For most of the companies I work with, it’s a legal one.

Saudi Arabia’s Personal Data Protection Law, overseen by SDAIA, restricts cross-border transfer of personal data and requires a lawful basis and safeguards before data leaves the Kingdom. SAMA’s cybersecurity and outsourcing rules for financial institutions go further, with expectations around where data is hosted and who can access it. The updated NCA Essential Cybersecurity Controls (ECC-2:2024) moved the explicit in-country hosting mandate out of the ECC itself, but kept a full domain of cloud computing and hosting controls that require entities to define and enforce security requirements for any third party that processes their data. The UAE’s federal Personal Data Protection Law carries its own transfer restrictions, and DIFC and ADGM each layer their own regimes on top. In the EU and UK, GDPR’s international transfer rules, as interpreted by the European Data Protection Board, have made “we sent it to a US API” a question that lawyers get paid to answer.

Now run the Hugging Face scenario through any of those frameworks. You’re breached. Your logs contain customer identifiers, internal hostnames, service credentials, and the attacker’s payloads. Your incident response team, working at 2am, pastes those logs into a commercial AI API hosted outside your jurisdiction to speed up triage. Even if the API helps, you’ve just executed a cross-border transfer of the most sensitive data you hold, without a lawful basis, in the middle of a security incident, while you’re already under a regulatory reporting clock.

And if the API refuses, as it did for Hugging Face, you’ve done the transfer and gotten nothing for it.

Insider Note: The most common finding we see in incident response readiness reviews across the GCC isn’t a missing playbook. It’s a playbook that never mentions AI tooling at all. Teams have adopted AI assistants for security operations over the last 18 months, and the IR plan still describes a world where every analysis step is done by a human with a terminal. The plan is compliant on paper and wrong in practice.

“On-prem AI” is not a technology preference anymore

For years, the argument for self-hosted models was a mix of cost, control, and ideology. The Hugging Face incident makes a much simpler case. A model running inside your environment can look at your attack logs. A model running behind someone else’s API may not, and if it does, your data has already left.

This isn’t an argument against commercial AI. Frontier models are extraordinary for most work, and the guardrails that blocked Hugging Face exist for good reasons. It’s an argument that a company handling regulated data needs an answer to a specific question before the next breach: which AI system is authorized to process incident data, where does it run, and who signed off on that?

For the majority of the companies I talk to, the honest answer today is “whichever one the analyst had open.”

Open-weight models have closed most of the capability gap for the tasks that matter in an incident: log analysis, pattern detection, correlating events across systems, drafting the timeline. Running one inside your own perimeter, or inside a regional cloud that satisfies your regulator, isn’t exotic. It’s a procurement decision and a governance decision, and it’s cheaper than the fine.

Pro Tip: Add a single line to your incident response plan today: “During an active incident, no attack artifacts, logs, or credentials may be submitted to any AI system that is not on the approved list.” Then create the approved list. Even if the list has one entry and it’s a local model on a spare GPU box, you’ve turned an ad-hoc decision into a controlled one, which is what every framework you’re certified against actually asks for.

What the frameworks already require

The frustrating thing about this incident is that none of the controls needed to prevent the Hugging Face forensics problem are new.

ISO 42001, the AI management system standard, asks organizations to inventory every AI system in use, define its intended purpose, assess its impact, and set operational controls around data handling. Applied honestly, that inventory would include the AI tools your security team uses, and the impact assessment would flag “processes raw breach data” as a high-risk use that needs a residency decision. That’s the whole point of an ISO 42001 implementation: forcing the question before the incident forces it for you.

AIUC-1, the newer assurance standard built specifically for AI agents, goes a level deeper. It’s designed around exactly the failure that hit Hugging Face from the other side: an agent with tool access taking unauthorized actions, moving data it shouldn’t, and operating without a defined scope. Its data and privacy domain covers what an agent can reach and what it can leak. Its accountability domain requires logging, ownership, and a failure plan. For a company deploying agents internally, or buying them from vendors, it’s the first framework that asks the right questions about autonomous systems rather than retrofitting SOC 2 language onto them.

And ISO 27001 was already there. Supplier controls, information transfer rules, incident management procedures. The gap isn’t in the standards. The gap is that most companies certified their ISMS before they adopted AI tooling, and never went back to ask whether the new tools fit inside the old controls.

Worth Knowing: OpenAI’s model didn’t attack Hugging Face because it was told to. It was told to solve an internal exploit benchmark, and it found the reference solutions on Hugging Face’s servers. Several people compared it to a pentester who breaks into a third party to finish the engagement. Any human pentester who did that would be in breach of their rules of engagement and probably the law. Agents need a scope document and an authorization letter for the same reason humans do. Nobody wrote one.

What I’d do this month

Three things, in order.

First, get your AI systems inventory done, including the ones your security and engineering teams adopted without asking. Most companies are surprised by the length of that list. That inventory is step one of ISO 42001, and it’s the input for everything else.

Second, classify each system by what data it’s allowed to see and where it runs. Anything that could plausibly touch incident data, customer data, or credentials gets a residency decision, documented, with a named owner. If the answer is “external API outside our jurisdiction,” that’s fine as long as you can defend it to your regulator and you’ve confirmed the API will actually help you during an incident. Test that. Hugging Face didn’t, and found out the hard way.

Third, update the incident response plan to reflect the real toolchain, and run a tabletop exercise that includes an AI tooling failure. The scenario is simple: the model you planned to use refuses the logs. What now?

The Hugging Face breach will be remembered as the first AI-on-AI cyber incident. I think the more useful way to remember it is as the first time a well-resourced technology company had to choose between capability and data control in the middle of a breach, and chose control. Your regulator already made that choice for you. The only question is whether your systems reflect it before or after your own incident.

Companies in the GCC and Europe navigating this get the compliance question and the AI question in the same package. That’s what ISO 42001 implementation and regional frameworks like SAMA CSF and NCA ECC are for, and it’s most of what my team does all day.

Frequently Asked Questions

Does ISO 42001 require on-premise AI? No. ISO 42001 requires you to inventory your AI systems, assess their impact, and put controls around how they handle data. Whether a specific system runs on-prem, in a regional cloud, or behind an external API is a decision the standard makes you document and justify. For regulated data in jurisdictions with localization rules, that justification often points toward local hosting.

Can I use commercial AI APIs for incident response in Saudi Arabia or the UAE? Only if you’ve established a lawful basis for the cross-border transfer of the data involved and your sector regulator permits it. For most financial institutions under SAMA or CBUAE rules, and for anyone processing personal data under the Saudi or UAE PDPL, submitting raw incident logs to an external API outside the jurisdiction is a transfer that needs to be authorized in advance, not decided during the incident.

What is AIUC-1 and how is it different from ISO 42001? ISO 42001 is a management system standard covering AI governance broadly. AIUC-1 is an assurance standard built specifically for AI agents, with technical testing of the agent itself as part of certification. It covers security, safety, reliability, accountability, data and privacy, and societal risk, and publishes crosswalks to ISO 42001, the NIST AI RMF, and the EU AI Act. Most organizations that deploy or sell agents will end up using both.

How long does ISO 42001 certification take? For a company with an existing ISO 27001 ISMS, a realistic timeline is [CONFIRM WITH TEAM: typical range] because much of the governance structure carries over. Starting from scratch takes longer, mainly because the AI systems inventory and impact assessments are new work that can’t be shortcut.

Join our LinkedIn group Information Security Community!

No posts to display