Vulnerability · Published Oct 25, 2024 · Assigned by GitHub_M

CVE-2024-49766Werkzeug safe_join not safe on Windows

Medium 6.3

In plain English

A medium-severity path traversal in werkzeug from pallets. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.8% (higher than 56% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 4.0)6.3Medium
Exploit odds (30 days)0.8%top 44.0% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

Werkzeug is a Web Server Gateway Interface web application library. On Python < 3.11 on Windows, os.path.isabs() does not catch UNC paths like //server/share. Werkzeug's safe_join() relies on this check, and so can produce a path that is not safe, potentially allowing unintended access to data. Applications using Python >= 3.11, or not using Windows, are not vulnerable. Werkzeug version 3.0.6 contains a patch.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
PyPIwerkzeug3.0.6GHSA-f9vj-2wh5-fj8j
PyPIwerkzeug3.0.6PYSEC-2026-2045

Affected products (as reported)

VendorProductVersions
pallets werkzeug < 3.0.6

Weakness: CWE-22 · Vector: CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N

References