CVE-2025-6638Medium· 5.3▾ SunlitHugging Face Transformers is vulnerable to ReDoS through its MarianTokenizer
▾ Sunlit zone — Low / medium · no exploitation signal
impact 29.2 · likelihood 0.1 · exploitation 0
Need a working PoC? Pro members can cast a request and our team develops one — it lands right here.
Exploit-prediction probability, daily snapshots since Jul 8.
Disclosure to exploitation, from the record and what we observed since indexing it.
Disclosed via OSV
0.5%
0.5% → 0.5%
Last analysed / modified upstream
A Regular Expression Denial of Service (ReDoS) vulnerability was discovered in the Hugging Face Transformers library, specifically affecting the MarianTokenizer's remove_language_code() method. This vulnerability is present in version 4.52.4 and has been fixed in version 4.53.0. The issue arises from inefficient regex processing, which can be exploited by crafted input strings containing malformed language code patterns, leading to excessive CPU consumption and potential denial of service.
transformers < 4.53.0Upgrade to a patched release:
transformers 4.53.0Connected by shared product, vendor, weakness, or advisory.
CVE-2025-6921Medium· 5.3Hugging Face Transformers vulnerable to Regular Expression Denial of Service (ReDoS) in the AdamWeightDecay optimizer
CVE-2024-11393High· 8.8Deserialization of Untrusted Data in Hugging Face Transformers
CVE-2024-11392High· 7.5Deserialization of Untrusted Data in Hugging Face Transformers
CVE-2024-11394High· 8.8Deserialization of Untrusted Data in Hugging Face Transformers
CVE-2026-9856High· 7.1A vulnerability in huggingface/transformers versions <=5.8.0.dev0 allows an attacker to perform arbitrary file writes via path traversal
CVE-2026-1839Medium· 6.5HuggingFace Transformers allows for arbitrary code execution in the `Trainer` class