# CVE-2025-3777: Improper Input Validation in huggingface/transformers

- Severity: Low 3.5 (CVSS:3.0, scored by @huntr_ai) `CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.42%, higher than 37% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2025-07-07T09:55:38.190Z
- Modified: 2026-09-10T03:50:26.198Z
- Also known as: GHSA-phhr-52qp-3mj4, PYSEC-2026-1986
- Weaknesses: CWE-20
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: @huntr_ai

## Description

Hugging Face Transformers versions up to 4.49.0 are affected by an improper input validation vulnerability in the `image_utils.py` file. The vulnerability arises from insecure URL validation using the `startswith()` method, which can be bypassed through URL username injection. This allows attackers to craft URLs that appear to be from YouTube but resolve to malicious domains, potentially leading to phishing attacks, malware distribution, or data exfiltration. The issue is fixed in version 4.52.1.

(As written by CVE List.)

## Affected

- huggingface huggingface/transformers: from unspecified before 4.52.1
- transformers (PyPI): before 4.52.1
- huggingface transformers: before 4.52.1

## Every score

- @huntr_ai: CVSS:3.0 3.5 Low `CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N`
- GitHub: CVSS:3.0 3.5 Low `CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N`
- PyPA Advisory Database: CVSS:3.0 3.5 Low `CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N`

## References

- <https://huntr.com/bounties/ccba0730-9248-4853-b7ff-5c20e6364f09> (exploit, third-party-advisory, web)
- <https://github.com/huggingface/transformers/commit/4dda5f71b35fb70cf602187eef84bb17a50b9082> (patch, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2025-3777> (advisory)
- <https://github.com/huggingface/transformers> (package)
- <https://github.com/huggingface/transformers/blame/a7d2bbaaa8aac64f7c1ee8c1421cfe84b38359a4/src/transformers/image_utils.py> (web)
- <https://pypi.org/project/transformers> (package)
- <https://github.com/advisories/GHSA-phhr-52qp-3mj4> (advisory)

## Sources

- CVE List: [CVE-2025-3777](https://www.cve.org/CVERecord?id=CVE-2025-3777), CVE Terms of Use, modified 2025-07-07
- GitHub Advisory Database: [GHSA-phhr-52qp-3mj4](https://github.com/advisories/GHSA-phhr-52qp-3mj4), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2025-3777](https://nvd.nist.gov/vuln/detail/CVE-2025-3777), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2026-1986](https://osv.dev/vulnerability/PYSEC-2026-1986), CC-BY-4.0, modified 2026-07-07

---

Page: https://cve.day/CVE-2025-3777 · Whole record: https://cve.day/CVE-2025-3777.json · Rebuilt by cve.day 2026-11-25T22:59:00.718Z
