CVE-2025-3933: huggingface/transformers · ReDoS
Affects huggingface/transformersSource CVE Database V5
Not known to be exploited · CVSS 5.3 Medium · fixed in 4.52.1 : update huggingface/transformers when convenient.
Data as of 26 Oct 2026, 10:12 UTC
- EPSS
- 0.4% chance of exploitation in 30 days – higher than 42% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 4.52.1
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:LExploitation evidence
Disclosed: evidence found.
CVE published 11 Jul 2025
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Affected software
| Product | Affected | Fixed in |
|---|---|---|
PyPItransformerspkg:pypi/transformersOther threats | Affected
| Fixed in– |
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
To mitigate CVE-2025-3933, European organizations should promptly upgrade the Hugging Face Transformers library to version 4.52.1 or later, where the vulnerability has been addressed. For environments where immediate upgrading is not feasible, implementing input validation and sanitization to detect and reject suspiciously crafted input strings targeting the `<s_(.*?)>` regex pattern can reduce exposure. Rate limiting and throttling API requests that invoke the DonutProcessor's token2json() method can help prevent resource exhaustion from repeated exploitation attempts. Monitoring CPU usage and setting alerts for anomalous spikes during document processing tasks can enable early detection of exploitation attempts. Additionally, isolating document processing workloads in containerized or sandboxed environments can limit the impact of potential denial of service conditions. Organizations should also review and update incident response plans to include scenarios involving ReDoS attacks on machine learning model APIs.
Description
A Regular Expression Denial of Service (ReDoS) vulnerability was discovered in the Hugging Face Transformers library, specifically within the DonutProcessor class's `token2json()` method. This vulnerability affects versions 4.50.3 and earlier, and is fixed in version 4.52.1. The issue arises from the regex pattern `<s_(.*?)>` which can be exploited to cause excessive CPU consumption through crafted input strings due to catastrophic backtracking. This vulnerability can lead to service disruption, resource exhaustion, and potential API service vulnerabilities, impacting document processing tasks using the Donut model.