Get a Demo

Let's Patch It!

Book a short call with one our specialists, we'll walk you through how Endor Patches work, and ask you a few questions about your environment (like your primary programming languages and repository management). We'll also send you an email right after you fill out the form, feel free to reply with any questions you have in advance!

CVE

CVE-2025-64712

Unstructured has Path Traversal via Malicious MSG Attachment that Allows Arbitrary File Write
Back to all
CVE

CVE-2025-64712

Unstructured has Path Traversal via Malicious MSG Attachment that Allows Arbitrary File Write

A Path Traversal vulnerability in the partition_msg function allows an attacker to write or overwrite arbitrary files on the filesystem when processing malicious MSG files with attachments.

  ## Impact

  An attacker can craft a malicious .msg file with attachment filenames containing path traversal sequences (e.g.,

  ../../../etc/cron.d/malicious). When processed with process_attachments=True, the library writes the attachment to an

  attacker-controlled path, potentially leading to:

  • Arbitrary file overwrite
  • Remote code execution (via overwriting configuration files, cron jobs, or Python packages)
  • Data corruption
  • Denial of service

  ## Affected Functionality

  The vulnerability affects the MSG file partitioning functionality when process_attachments=True is enabled.

  ## Vulnerability Details

  The library does not sanitize attachment filenames in MSG files before using them in file write operations, allowing directory

  traversal sequences to escape the intended output directory.

  ## Workarounds

  Until patched, users can:

  • Set process_attachments=False when processing untrusted MSG files
  • Avoid processing MSG files from untrusted sources
  • Implement additional filename validation before processing

Package Versions Affected

Package Version
patch Availability
No items found.

Automatically patch vulnerabilities without upgrading

Fix Without Upgrading
Detect compatible fix
Apply safe remediation
Fix with a single pull request

CVSS Version

Severity
Base Score
CVSS Version
Score Vector
C
H
U
9.8
-
3.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
C
H
U
0
-
3.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
C
H
U
9.8
-
3.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Related Resources

No items found.

References

https://github.com/Unstructured-IO/unstructured/security/advisories/GHSA-gm8q-m8mv-jj5m, https://nvd.nist.gov/vuln/detail/CVE-2025-64712, https://github.com/Unstructured-IO/unstructured/commit/b01d35b2373fd087d2e15162b9c021663c97155d, https://github.com/Unstructured-IO/unstructured

Severity

9.8

CVSS Score
0
10

Basic Information

Ecosystem
Base CVSS
9.8
EPSS Probability
0.00085%
EPSS Percentile
0.24687%
Introduced Version
0,0.15.14,0.14.5,0.13.7,0.13.0,0.10.20,0.10.15,0.8.5,0.8.3,0.7.12,0.7.11
Fix Available
0.18.18

Fix Critical Vulnerabilities Instantly

Secure your app without upgrading.
Fix Without Upgrading