Ingenious AI

Ingenious AI · Model supply chain · Free self-check

Before you load that Hugging Face model, preflight it

On 24 November 2026, JFrog Security Research disclosed the ARTEX campaign: 13 fake Hugging Face repositories whose “models” were credential stealers with three ways to run code on load — config.json auto_map remote code under trust_remote_code, malicious pickles inside .bin weights (including the legacy concatenated format), and a chat-template Jinja escape — exfiltrating environment and Kubernetes credentials through Hugging Face's own commit API with an embedded write token. Hugging Face's scanner flagged only the pickles. This page runs the pre-load audit the scanner did not: on the repo's real public metadata, before anything is loaded.

What this does — and does not do

Does: (1) Option A — for a public repo id you enter, fetches that repo's public metadata from the Hugging Face API (api/models/<id>, the file tree with sizes, and config.json / tokenizer_config.json / README.md via the resolve endpoints) and checks it for the ARTEX tells: auto_map remote code, pickle-format weights, weight files absurdly smaller than a real model, weightless repos with executable surface, chat-template Jinja escape primitives, embedded hf_ token shapes and Hub commit-API references. (2) Option B — runs the same checks locally on a config and file list you paste. Token-shaped strings are counted and discarded: their values are never displayed, logged or sent anywhere.

Does not: download weights, load or execute the model, scan inside binary weight files (the legacy concatenated pickle format cannot be ruled in or out from metadata — the page says so where it matters), or judge private/gated repos it cannot read. A clean preflight covers the tells listed here; it is not a safety verdict on the repo.

Option A — Preflight a public repo by id

Option B — Paste config + file list

The facts behind this check

JFrog's timeline is the tell-list. The first fake model, llama-3.2-1b-tuned, promised a fine-tuned 1B instruct model; every .bin was about 2.5 KB, where a real 1B model weighs more than two gigabytes. Its payload collected the first process's environment and a Kubernetes service-account token into roughly 16 KB of JSON and committed it as loot files to the attacker's public repositories through the Hub commit API (POST /api/models/<user>/<repo>/commit/main) with an embedded HF write token — no separate command-and-control server, riding egress most ML workload policies allow. The agent then adapted: the final variant carried no weights at all — just a config, a borrowed tokenizer and two Python files — and passed with no warning. JFrog assesses with high confidence the models were built and tested inside an autonomous ARTEX agent task; the first loot file was the operator's own environment, leaked 14 seconds after upload. Hugging Face disabled all 13 repositories the same day. Defences that hold: avoid trust_remote_code on unreviewed repos, prefer safetensors, use torch ≥ 2.6 with weights_only=True, render chat templates only in a sandbox, pin revisions to a commit SHA, and alert on Hub writes from model-serving workloads.

Frequently asked questions

What does the preflight check on a Hugging Face repo?

It checks the repo for the ARTEX load-time execution tells: auto_map remote code, pickle-format weights, weight files absurdly smaller than a real model, weightless repos with executable surface, chat-template Jinja escape primitives, embedded hf_ token shapes and Hub commit-API references.

Does it download or load the model?

No. Option A fetches public metadata only: the model API record, the file tree with sizes, and config files through the resolve endpoints. It does not download weights, load the model or execute anything, and Option B runs the same checks locally on material you paste.

What happens to token-shaped strings it finds?

They are counted and discarded. Their values are never displayed, logged or sent anywhere, in either option.

A repo came back clean. Is it safe to load?

A clean preflight covers the tells listed on this page; it is not a safety verdict on the repo. The page is also plain about one limit: the legacy concatenated pickle format cannot be ruled in or out from metadata, so that uncertainty is stated where it matters rather than hidden.

What habits does the page recommend around loading models?

Avoid trust_remote_code on unreviewed repos, prefer safetensors, use torch 2.6 or later with weights_only set to True, render chat templates only in a sandbox, pin revisions to a commit SHA, and alert on Hub writes from model-serving workloads.

Sources

JFrog Security Research — The Agent That Robbed Itself (24 Nov 2026)

Loading other people's models in production? TrustGate watches the tools and models your agents actually run. This page is a one-off preflight, not monitoring.

← Back to Ingenious AI home