Quick answers
- Is CVE-2025-3933 exploited in the wild?
- No. Junglewise Threat Intelligence has no report of CVE-2025-3933 being exploited in the wild.
- How severe is CVE-2025-3933?
- Low severity, with a CVSS score of 3.1, published 7 July 2026.
- Which products and versions are affected?
- Hugging Face Transformers <=4.51.3; transformers (PyPI) ECOSYSTEM:introduced=0,fixed=4.52.1.
- Is there a fix for CVE-2025-3933?
- Yes. transformers (PyPI): upgrade to 4.52.1 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
- How is CVE-2025-3933 attacked?
- It is attacked over the network.
- Am I affected by CVE-2025-3933?
- Check whether you run Hugging Face Transformers or transformers (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.
How to fix
- transformers (PyPI): upgrade to 4.52.1 or later
pip install "transformers>=4.52.1"
Technical details
A Regular Expression Denial of Service (ReDoS) vulnerability exists in the DonutProcessor class's token2json() method, triggered by the regex pattern <s_(.*?)> which is vulnerable to catastrophic backtracking. The vulnerability affects all versions up to and including 4.51.3, with a fix available in version 4.52.1. An attacker can craft malicious input strings to cause excessive CPU consumption, leading to service disruption and resource exhaustion, particularly impacting API services and document processing tasks. The vulnerability is triggered through network input if the affected service processes user-supplied documents, and no authentication is typically required to exploit it. A patch is available and should be applied immediately by upgrading to version 4.52.1 or later.
Affected products
- Hugging Face Transformers <=4.51.3
Identifiers
- CVE-2025-3933
- GHSA-37mw-44qp-f5jm
- PYSEC-2026-1977
Timeline
- 2025-07-11: disclosed
- 2025-05-06: patched: Fix merged in PR #37788; version 4.52.1 contains the patch