transformers

Transformers: the model-definition framework for state-of-the-art machine learning models in text, vision, audio, and multimodal models, for both inference and training.

5.25.1Latest, 2 Dec 2026
12MDownloads, last month
0Advisories on the latest
40Advisories, all versions
Apache 2.0 LicenseLicence
169KStars
6.4/10OpenSSF Scorecard

Known advisories

Severity Advisory Fix Published
Hugging Face Transformers downloads custom generation code before trust consent CVE-2026-80047 No fix listed 1 Oct 2026
Transformers save_pretrained path traversal allows arbitrary file writes through chat template names CVE-2026-9856 Fixed in 5.10.0 10 Sep 2026
High Hugging Face Transformers downloads custom generation code before trust consent CVE-2026-80047 No fix listed 1 Sep 2026
High Transformers save_pretrained path traversal allows arbitrary file writes through chat template names CVE-2026-9856 Fixed in 5.10.0 2 Aug 2026
Transformers is vulnerable to ReDoS attack through its DonutProcessor class CVE-2025-3933 Fixed in 4.52.1 7 Jul 2026
Transformers Deserialization of Untrusted Data vulnerability CVE-2024-3568 Fixed in 4.38.0 7 Jul 2026
Transformers vulnerable to ReDoS attack through its SETTING_RE variable CVE-2025-3262 Fixed in 4.51.0 7 Jul 2026
Hugging Face Transformers vulnerable to Regular Expression Denial of Service (ReDoS) in the AdamWeightDecay optimizer CVE-2025-6921 Fixed in 4.53.0 7 Jul 2026
Hugging Face Transformers is vulnerable to ReDoS through its MarianTokenizer CVE-2025-6638 Fixed in 4.53.0 7 Jul 2026
Transformers Regular Expression Denial of Service (ReDoS) vulnerability CVE-2024-12720 Fixed in 4.48.0 7 Jul 2026
Hugging Face Transformers Regular Expression Denial of Service (ReDoS) vulnerability CVE-2025-5197 Fixed in 4.53.0 7 Jul 2026
Transformers Regular Expression Denial of Service (ReDoS) vulnerability CVE-2025-1194 Fixed in 4.50.0 7 Jul 2026
Transformers vulnerable to ReDoS attack through its get_imports() function CVE-2025-3264 Fixed in 4.51.0 7 Jul 2026
Transformers's Improper Input Validation vulnerability can be exploited through username injection CVE-2025-3777 Fixed in 4.52.1 7 Jul 2026
Transformers's ReDoS vulnerability in get_configuration_file can lead to catastrophic backtracking CVE-2025-3263 Fixed in 4.51.0 7 Jul 2026

In the news

On Hacker News

Sources: PyPI, deps.dev (CC BY 4.0), OSV. Last checked 3 Dec 2026.