patchminder
Proof of concept · GitHub CVE-2026-4372

Remote code executionin Hugging Face Transformers.

Published 24 May 2026 · Updated 26 May 2026 · Every fact sourced

JSONCite
Is it exploited?
Not confirmed

Proof of concept public (GitHub).

Attack code is public
Severity
High 7.8
CVSSA severity score from 0 to 10. 9 and higher is critical. 3.0 · no login needed
Attack likelihood
Low
EPSSA daily score from FIRST: the chance a hole is attacked in the next 30 days. 0.7% chance in 30 days · 4 Dec 2026
Fix
Available
Upgrade to 5.3.0 or later
In plain words

A critical remote code execution vulnerability exists in all versions of the HuggingFace transformers library prior to version 5.3.0. The vulnerability allows an attacker to craft a malicious `config.json` file containing the `_attn_implementation_internal` field set to an attacker-controlled HuggingFace Hub repository ID. When a victim loads this model using the standard `AutoModelForCausalLM.from_pretrained()` API, the library downloads and executes arbitrary Python code from the attacker's repository with the victim's full OS privileges. This issue arises due to unfiltered deserialization of configuration attributes, insufficient sanitization of internal fields, and unsandboxed execution of downloaded kernels.

What to do now
  • Upgrade huggingface/transformers to 5.3.0 or later.
  • Upgrade transformers (PyPI) to 5.3.0 or later.
Versions

Affected and fixed versions

Product or package
Affected
Fixed in
Source
huggingface/transformers
before 5.3.0
5.3.0
CVE record
transformers (PyPI)
before 5.3.0
5.3.0
GitHub advisory

From the CVE record, NVD and package advisories. When no source has versions yet, this table says "not confirmed" instead of guessing.

Timeline

From first report to first attacks

  1. 18 Mar 2026
    CVE ID reserved by @huntr_ai.
  2. 24 May 2026
    Published in the CVE List.
  3. 26 May 2026
    CVE record last updated.
  4. 14 Oct 2026
    First public proof of concept on GitHub.
Exploit code

Attack code anyone can find

Exploit maturity: Proof of concept (GitHub). CISA assessment (SSVC): exploitation none.

Metasploit module
None known
Nuclei scan template
None known
Exploit-DB
None known
GitHub proof of concepts
1 repository
GitHubno warning signs foundalvin21mfmlai/SE6013_Project0 stars · created 14 Oct 2026CVE-2026-4372: Threat Model, Root-Cause Analysis, Replication & Detection

Listed so defenders can judge how urgent this is and test systems they are authorised to test. Patchminder does not host exploit code; links open the source page. Labels for GitHub repositories come from their public details and are never a promise about the code. Run anything only in an isolated lab.

Related

Other Transformers vulnerabilities

References
Cite this page

Patchminder. CVE-2026-4372: Remote code execution in Hugging Face Transformers. https://patchminder.com/cve/cve-2026-4372/ (accessed 5 December 2026).