CVE-2022-41905 wsgidav is vulnerable to Cross-Site Scripting (XSS) when directory browsing is enabled

High 8.2 Published Updated

Attackers can execute arbitrary scripts in user browsers via XSS in WsgiDAV when directory browsing is enabled.

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

What is CVE-2022-41905?

CVE-2022-41905 is a high-severity cross-site scripting vulnerability in mar10 wsgidav, published on 11 Nov 2022. 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

WsgiDAV is a generic and extendable WebDAV server based on WSGI. Implementations using this library with directory browsing enabled may be susceptible to Cross Site Scripting (XSS) attacks. This issue has been patched, users can upgrade to version 4.1.0. As a workaround, set `dir_browser.enable = False` in the configuration.

Weakness: CWE-79

Which versions are affected by CVE-2022-41905?

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

PackageAffectedFixed in
wsgidav PyPIFrom 3.0.04.1.0
wsgidav PyPIFrom 3.0.0a14.1.0
wsgidav PyPIFrom 3.0.0a14.1.0

Products include Wsgidav Project Wsgidav.

How do I fix CVE-2022-41905?

Upgrade wsgidav to 4.1.0 or later.

Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.

Is CVE-2022-41905 being exploited?

There is no known exploitation of CVE-2022-41905 in the wild and no public exploit code.

Sources

Also known as GHSA-xx6g-jj35-pxjv, PYSEC-2022-43018.

Is CVE-2022-41905 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free