Critical Vulnerability in python-setuptools: Path Sanitization Flaw
Summary
USN-7544-1: python-setuptools, setuptools vulnerability. Affects python-setuptools versions < 3.3-1ubuntu2+esm3. Fixed in 3.3-1ubuntu2+esm3. How to fix ↓
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.
No signup required · Results in about 60 seconds
Background
python-setuptools is a widely used package in the Python ecosystem that facilitates the packaging of Python projects. It provides essential tools for building and distributing Python packages, making it a critical component for developers. However, recent findings have revealed a significant vulnerability that compromises its security, allowing potential attackers to exploit the package.
Vulnerability Detail
The vulnerability stems from improper path sanitization within the setuptools package. This flaw allows an attacker to manipulate file paths, potentially leading to unauthorized file writes in arbitrary locations on the filesystem. The issue is classified under CVE-2025-47273, indicating its severity and the risk it poses to systems utilizing affected versions of the package.
How To Fix
Minimum fixed version
3.3-1ubuntu2+esm3
This is the first release that contains the fix.
sudo apt-get install --only-upgrade python-setuptools
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
As a temporary workaround, users are advised to restrict file write permissions for the directories where setuptools operates, minimizing the risk of unauthorized file writes until the package is updated.
Conclusion
In summary, the python-setuptools package has a critical vulnerability related to path sanitization that could lead to unauthorized file writes. Users are urged to update to the latest patched version to mitigate this risk. Utilizing tools like Vulert can help monitor and manage vulnerabilities effectively.
See every vulnerability recorded for python-setuptools →
FAQ
The vulnerability involves improper path sanitization, which could allow attackers to write files to arbitrary locations on the filesystem.
You can use Vulert, which monitors and alerts for open-source vulnerabilities in your software. Simply upload your manifest file like package-lock.json to check for vulnerabilities.
If exploited, this vulnerability could lead to unauthorized access and modification of files on the affected system, posing a significant security risk.
Yes, you should update to the patched version of python-setuptools. For example, use 'sudo apt-get install python-setuptools=3.3-1ubuntu2+esm3' for Ubuntu 14.04.
Detailed information can be found in the Ubuntu Security Notices and the CVE database, specifically under CVE-2025-47273.
References
Related vulnerabilities
Recent vulnerabilities recorded for python-setuptools.