CVE-2026-3029: PyMuPDF Path Traversal and Arbitrary File Write Vulnerability

pymupdf Updated 19 Mar 2026

Summary

19/03/2026
Yes i
Moderate
6.9

CVE-2026-3029: PyMuPDF has a path traversal in _main_.py. Affects pymupdf versions >= 1.26.5, < 1.26.7. Fixed in 1.26.7. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

PyMuPDF is a popular open-source library for working with PDF documents and other document formats. It allows users to create, manipulate, and extract information from PDFs with ease. The library is widely used in various applications due to its efficiency and rich feature set. However, a recent vulnerability has been identified in version 1.26.5, which could potentially allow malicious actors to exploit the library for unauthorized file access and manipulation.

Vulnerability Detail

A path traversal and arbitrary file write vulnerability exists in the embedded get function within 'main.py' of PyMuPDF version 1.26.5. This vulnerability allows attackers to craft requests that can write files to arbitrary locations on the server, leading to potential data breaches or unauthorized file modifications. The issue arises from improper validation of user input, which can be exploited to traverse the file system and access sensitive files.

How To Fix

Minimum fixed version

1.26.7

This is the first release that contains the fix.

pip install --upgrade "pymupdf==1.26.7"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If an immediate update is not feasible, consider implementing input validation to restrict file paths and prevent traversal attacks. Ensure that user inputs are sanitized and validated against a whitelist of acceptable paths.

Conclusion

The identified vulnerability in PyMuPDF poses significant risks related to unauthorized file access and manipulation. It is crucial for users of the library to update to the latest version to ensure their applications remain secure. Additionally, implementing proper input validation can help mitigate potential risks until an update can be applied.

See every vulnerability recorded for pymupdf →

Share this vulnerability

FAQ

The vulnerability is a path traversal and arbitrary file write issue that allows unauthorized file access and manipulation.

The vulnerability affects PyMuPDF version 1.26.5. Versions 1.26.7 and later have the issue fixed.

You can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

The CVSS score of this vulnerability is 6.9, indicating a moderate level of severity.

If an immediate update is not possible, implement strict input validation to mitigate the risk of exploitation.

Related vulnerabilities

Recent vulnerabilities recorded for pymupdf.

How To Fix

Minimum fixed version

1.26.7

This is the first release that contains the fix.

pip install --upgrade "pymupdf==1.26.7"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback