{"id":"CVE-2025-3933","published":"2025-07-11T09:22:27Z","modified":"2025-07-11T15:07:34Z","title":"Regular Expression Denial of Service (ReDoS) in huggingface/transformers","vendor":"huggingface","product":"huggingface/transformers","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.3,"severity":"MEDIUM","version":"3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00496,"percentile":0.4345,"provenance":"source"},"cwes":[{"id":"CWE-1333","name":"Inefficient Regular Expression Complexity"}],"references":[{"url":"https://huntr.com/bounties/25282953-5827-4384-bb6f-5790d275721b","tags":[]},{"url":"https://github.com/huggingface/transformers/commit/ebbe9b12dd75b69f92100d684c47f923ee262a93","tags":[]}],"priority":{"score":12.4,"factors":[{"name":"EPSS percentile","points":8.69},{"name":"CVSS severity","points":3.71}]},"vendorSlug":"huggingface","affectedVersions":[{"vendor":"huggingface","product":"huggingface/transformers","versions":[">= unspecified, < 4.52.1"]}],"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"partial","timestamp":"2025-07-11T14:34:20.168976Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"transformers","vulnerableRanges":["<4.52.1"],"patched":["4.52.1"],"from":["GHSA-37mw-44qp-f5jm","PYSEC-2026-1977"],"provenance":"source"}],"summary":{"text":"A Regular Expression Denial of Service (ReDoS) flaw exists in the DonutProcessor class's token2json() method of the Hugging Face Transformers library (huggingface/transformers), caused by the regex pattern <s_(.*?)>. An unauthenticated remote attacker over the network, with no user interaction and no special configuration required, can send a crafted input string that triggers catastrophic backtracking, consuming excessive CPU and disrupting document processing that uses the Donut model.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:52:53Z"},"euvd":{"id":"EUVD-2025-21126","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2025-3263","published":"2025-07-07","fixed":"4.51.0","kev":false,"link":{"from":"CVE-2025-3263","to":"CVE-2025-3933","relation":"successor","confidence":"medium","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:transformers","fromFixed":"4.51.0","toFixed":"4.52.1","daysApart":4},{"kind":"similar","provenance":"machine","score":0.35,"basis":"same product + CWE + description similarity"}]}},{"cve":"CVE-2025-3264","published":"2025-07-07","fixed":"4.51.0","kev":false},{"cve":"CVE-2025-3777","published":"2025-07-07","fixed":"4.52.1","kev":false},{"cve":"CVE-2025-3933","published":"2025-07-11","fixed":"4.52.1","kev":false},{"cve":"CVE-2025-5197","published":"2025-08-06","fixed":"4.53.0","kev":false},{"cve":"CVE-2025-6051","published":"2025-09-14","fixed":"4.53.0","kev":false},{"cve":"CVE-2025-6638","published":"2025-09-12","fixed":"4.53.0","kev":false}],"package":"PyPI:transformers"}}