CVE-2026-102598: Werkzeug path traversal via NUL device with NTFS ADS marker

CVE-2026-102598 · Severity: medium · CVSS 4 · Published 2026-09-29

Werkzeug's send_from_directory function can be bypassed on Windows systems to open special device files like NUL when a request includes an empty NTFS Alternate Data Stream (ADS) marker. An attacker can craft a malicious path to cause the application to hang indefinitely, resulting in a denial of service.

Technologies: werkzeug (PyPI). Vendors: Pallets, PyPI.

Quick answers

Is CVE-2026-102598 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-102598 being exploited in the wild.
How severe is CVE-2026-102598?
Medium severity, with a CVSS score of 4, published 29 September 2026.
Which products and versions are affected?
Pallets Werkzeug before 3.1.9; werkzeug (PyPI) < 3.1.9, ECOSYSTEM:introduced=0,fixed=3.1.9.
Is there a fix for CVE-2026-102598?
Yes. werkzeug (PyPI): upgrade to 3.1.9 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-102598 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-102598?
Check whether you run Pallets Werkzeug or werkzeug (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

  • werkzeug (PyPI): upgrade to 3.1.9 or later
    pip install "werkzeug>=3.1.9"

Technical details

The safe_join function fails to sanitize Windows special device names (NUL, CON, PRN, etc.) when they include an empty ADS marker (colon suffix). The vulnerability requires the application to run on Windows with NTFS and use send_from_directory with user-controlled input. An attacker can trigger an indefinite file read hang by requesting a path ending in a special device name, such as "NUL:".

Affected products

  • Pallets Werkzeug before 3.1.9

Identifiers

  • CVE-2026-102598
  • GHSA-g6x2-hccm-hh4m
  • PYSEC-2026-4312

Timeline

  • 2026-09-29: disclosed
  • 2026-09-27: patched

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.