AI hack · Security research · 13 Jan 2026No abuse seen by Dec 2025, Unit 42 saysNeMo fixed in 2.3.2, The Register saysAccounts of the Hydra block-list differ
Unit 42 found AI libraries from NVIDIA, Salesforce and Apple could run code hidden in a model file's metadata
In January 2026, Palo Alto Networks' Unit 42 showed that NeMo, Uni2TS and FlexTok, AI libraries from NVIDIA, Salesforce and Apple, could run code 2 sourcesPalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-handThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 as soon as the file loaded. The maintainers have issued fixes and, in two cases, CVEs, The Register reports. Unit 42 says it had found 2 sourcesPalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-handThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 in the wild as of December 2025.
By Chris Hoskins, Founder, Boogey ·
Tap underlined words to see who reported them.
Tens of millions
SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand
700+
SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026
Almost 50
SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026
2.3.2
SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026
How a model file could run code, according to Unit 42
Step 1
Settings in the file
NeMo, Uni2TS and FlexTok keep a model's settings in its metadata. They all 2 sourcesPalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-handThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026, a Python library Meta maintains, to create the model's parts from those settings.
Step 2
Any function will do
Hydra's instantiate() function takes SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand, not just a class, and calls it with the arguments given. The libraries appear to have overlooked that, Unit 42 says.
Step 3
No check first
Vulnerable versions passed a model file's metadata to that function 2 sourcesPalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-handThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026.
Step 4
Code on load
So code tucked into the metadata 2 sourcesPalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-handThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 when the file is loaded.
“Attackers would just need to create a modification of an existing popular model, with either a real or claimed benefit, and then add malicious metadata.”
Why a safe format didn't stop it
Pickle, an older Python format, SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand. Unit 42 says most popular AI libraries document that risk and block unexpected code by default.
Safe formats, open readers
Newer formats such as SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand don't make the software that reads them impervious, Unit 42 says. JFrog has found flaws in such apps too.
Metadata out of sight
Hugging Face doesn't make metadata as easy to see as other files, nor flag safetensors or NeMo files as SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026, The Register notes.
The fixes, and Hydra's
Palo Alto Networks says it told SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand in April 2025, before publishing. NVIDIA tracks the NeMo flaw as CVE-2025-23304, rated high severity, and fixed it in SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026, The Register reports. Salesforce issued CVE-2026-22584 and SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 on 31 July 2025, The Register reports. A Salesforce spokesperson told The Register it has no evidence of unauthorised access to customer data. The other companies and Hugging Face SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 to The Register. Apple and EPFL VILAB have SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 as well, The Register says. Unit 42 says Hydra has since added a warning to its documentation that instantiate() can run code, and SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand of dangerous functions. The Register says Meta, which maintains Hydra, added the warning and advice to use a block-list. As of 13 January 2026, it says, the block-list 2 sourcesPalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-handThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026. Unit 42 adds that the block-list matches exact names, so it is SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand by reaching the same functions another way.
The Boogey fix
Could a model file you load run code in your product?
You’re exposed if
- Your product loads models or model files from outside, such as Hugging Face, a partner, or uploads from your users.
- It loads them with NeMo, Uni2TS, FlexTok, or any library that hands model metadata to Hydra's instantiate().
- Your agent or pipeline can fetch a model on request, with no list of approved models.
- Model loading runs inside a service that also holds your keys, customer data or network access.
Fix it
01A version floor at NeMo 2.3.2
Make your build fail if it contains NeMo below 2.3.2, SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026, The Register reports. Set the same kind of floor for Uni2TS and FlexTok at the fixed releases their maintainers name.
02Allow only your own classes
Before metadata reaches instantiate() or any loader like it, check each target it names against a short list of your own model classes, and refuse everything else. Unit 42 says a block-list of exact names is SourcePalo Alto Networks Unit 42Remote Code Execution With Modern AI/ML Formats and Libraries13 Jan 2026 · first-hand.
03Load in a sealed box
Open outside model files in a separate process with no keys, no customer data and no outbound network, and pass on only the weights.
04Pinned models only
Pin every outside model to a reviewed version and file hash, and have your agent refuse to fetch any model not on that list. Carmony says an attacker need only SourceThe RegisterPopular Python libraries used in Hugging Face models subject to poisoned metadata attack13 Jan 2026 and add malicious metadata.
On your platform
Settings you already have that help against this hack. Last checked 1 Dec 2026.
No setting on Claude Code helps with this one. Our test does.
How we test it
- 1Under a signed scope, in your staging only, you share your lockfile and the code that loads models, read-only. From the lockfile, we flag NeMo below 2.3.2 and Uni2TS below 2.0.0. Nothing gets installed.
- 2From the code, we flag every model your product downloads without a pinned commit.
- 3A test user asks your agent to fetch a model that isn’t on your approved list, an ordinary one we host with plain metadata. The test user notes whether your agent refuses, asks first or fetches it.Being built
- Built
- BT-08 · Vulnerable MCP server, agent framework or AI library codeBT-22 · Model and AI supply chain
It fails if
- Your lockfile has NeMo below 2.3.2, or Uni2TS below 2.0.0
- Your product downloads a model without a pinned commit
- Your agent fetches a model that isn’t on your list without asking the test user
Does your product load model files that someone else made? We'll run this test on yours. Part of it is still being built.
What it reveals
A safe file format keeps code out of the weights, but the settings beside them still tell your loader what to build, so check them as you would code.