# CVE-2025-66034: fontTools is Vulnerable to Arbitrary File Write and XML injection in fontTools.varLib

> Attackers can achieve remote code execution by tricking users into processing a malicious .designspace file with the fontTools varLib script.

- **Severity:** Medium 6.3 (`CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:C/C:N/I:H/A:L`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Local or same network only
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 29 Nov 2025
- **Updated:** 1 Dec 2025
- **Also known as:** BELL-CVE-2025-66034, DEBIAN-CVE-2025-66034, GHSA-768j-98cg-p3fv, PYSEC-2026-1389, SUSE-SU-2026:0199-1, SUSE-SU-2026:20184-1, UBUNTU-CVE-2025-66034, openSUSE-SU-2026:10076-1, openSUSE-SU-2026:20119-1

## What is CVE-2025-66034?

CVE-2025-66034 is a medium-severity code injection vulnerability in fonttools, published on 29 Nov 2025. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

### Official description

fontTools is a library for manipulating fonts, written in Python. In versions from 4.33.0 to before 4.60.2, the fonttools varLib (or python3 -m fontTools.varLib) script has an arbitrary file write vulnerability that leads to remote code execution when a malicious .designspace file is processed. The vulnerability affects the main() code path of fontTools.varLib, used by the fonttools varLib CLI and any code that invokes fontTools.varLib.main(). This issue has been patched in version 4.60.2.

Weakness: CWE-91 (XML Injection)

## Which versions are affected by CVE-2025-66034?

3 open source packages ship an affected version, including fonttools. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `fonttools` | PyPI | From 4.33.0 | 4.60.2 |
| `fonttools` | PyPI | From 4.33.0 | 4.60.2 |
| `fonttools` | PyPI | From 4.33.0 | 4.60.2 |
| `python-FontTools` | SUSE:Linux Enterprise Module for Package Hub 15 SP7 | All versions | 4.47.2-150600.3.3.1 |
| `python-FontTools` | SUSE:Linux Enterprise Server 16.0 | All versions | 4.53.1-160000.3.1 |
| `python-FontTools` | SUSE:Linux Enterprise Server for SAP applications 16.0 | All versions | 4.53.1-160000.3.1 |
| `python-FontTools` | openSUSE:Leap 15.6 | All versions | 4.47.2-150600.3.3.1 |
| `python-FontTools` | openSUSE:Leap 16.0 | All versions | 4.53.1-160000.3.1 |
| `python-FontTools` | openSUSE:Tumbleweed | All versions | 4.61.1-1.1 |

Products: Fonttools Fonttools.

## How do I fix CVE-2025-66034?

Upgrade fonttools to 4.60.2 or later.

## Is CVE-2025-66034 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-66034 exists.

Public exploit code:

- https://github.com/v3cn4x00/POC-CVE-2025-66034 (github_poc): https://github.com/v3cn4x00/POC-CVE-2025-66034
- Proof-of-concept exploit for CVE-2025-66034 in the fontTools variable font generation pipeline. A crafted .designspace file allows control of the output path, enabling arbitrary file writes. The script automates payload creation, font generation, and upload to demonstrate the issue. (github_poc): https://github.com/symphony2colour/varlib-cve-2025-66034
- https://github.com/Liquid-Sec/Variatype.htb-CVE-2025-66034 (github_poc): https://github.com/Liquid-Sec/Variatype.htb-CVE-2025-66034
- CVE-2025-66034 exploit and documentation (github_poc): https://github.com/tristanqtn/CVE-2025-66034
- https://github.com/jwsly12/CVE-2025-66034-htb-ctf (github_poc): https://github.com/jwsly12/CVE-2025-66034-htb-ctf
- CVE-2025-66034 - fontTools varLib Arbitrary File Write → RCE  PoC exploit for an Arbitrary File Write + XML Injection vulnerability in fontTools.varLib. (github_poc): https://github.com/4nuxd/CVE-2025-66034

## Other vulnerabilities in fonttools

- [CVE-2023-45139](https://insights.sbomify.com/CVE-2023-45139/): fonttools XML External Entity Injection (XXE) Vulnerability (high 7.5)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2025-66034 and fix it if it is affected.

What it is: CVE-2025-66034 is a medium-severity code injection vulnerability in fonttools, published on 29 Nov 2025. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-66034 exists.

Affected packages and fixed versions:
- fonttools (PyPI): affected from 4.33.0; fixed in 4.60.2
- fonttools (PyPI): affected from 4.33.0; fixed in 4.60.2
- fonttools (PyPI): affected from 4.33.0; fixed in 4.60.2

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2025-66034/ (Markdown: https://insights.sbomify.com/CVE-2025-66034/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2025-66034
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2025-66034
- OSV: https://osv.dev/vulnerability/CVE-2025-66034

---
From sbomify Insights: https://insights.sbomify.com/CVE-2025-66034/
Summaries are generated and may contain mistakes; the official description above is the record.
