Amazon Linux 2 Security Advisory: ALAS-2025-2815
Advisory Release Date: 2025-03-26 19:24 Pacific
Advisory Updated Date: 2025-04-01 16:23 Pacific
Directory traversal vulnerability in the (1) extract and (2) extractall functions in the tarfile module in Python allows user-assisted remote attackers to overwrite arbitrary files via a .. (dot dot) sequence in filenames in a TAR archive, a related issue to CVE-2001-1267. (CVE-2007-4559)
A vulnerability has been found in the CPython `venv` module and CLI where path names provided when creating a virtual environment were not quoted properly, allowing the creator to inject commands into virtual environment "activation" scripts (ie "source venv/bin/activate"). This means that attacker-controlled virtual environments are able to run commands when the virtual environment is activated. Virtual environments which are not created by an attacker or which aren't activated before being used (ie "./venv/bin/python") are not affected. (CVE-2024-9287)
The Python standard library functions `urllib.parse.urlsplit` and `urlparse` accepted domain names that included square brackets which isn't valid according to RFC 3986. Square brackets are only meant to be used as delimiters for specifying IPv6 and IPvFuture hosts in URLs. This could result in differential parsing across the Python URL parser and other specification-compliant URL parsers. (CVE-2025-0938)
Affected Packages:
python3
Note:
This advisory is applicable to Amazon Linux 2 (AL2) Core repository. Visit this FAQ section for the difference between AL2 Core and AL2 Extras advisories.
Issue Correction:
Run yum update python3 to update your system.
aarch64:
python3-3.7.16-1.amzn2.0.14.aarch64
python3-libs-3.7.16-1.amzn2.0.14.aarch64
python3-devel-3.7.16-1.amzn2.0.14.aarch64
python3-tools-3.7.16-1.amzn2.0.14.aarch64
python3-tkinter-3.7.16-1.amzn2.0.14.aarch64
python3-test-3.7.16-1.amzn2.0.14.aarch64
python3-debug-3.7.16-1.amzn2.0.14.aarch64
python3-debuginfo-3.7.16-1.amzn2.0.14.aarch64
i686:
python3-3.7.16-1.amzn2.0.14.i686
python3-libs-3.7.16-1.amzn2.0.14.i686
python3-devel-3.7.16-1.amzn2.0.14.i686
python3-tools-3.7.16-1.amzn2.0.14.i686
python3-tkinter-3.7.16-1.amzn2.0.14.i686
python3-test-3.7.16-1.amzn2.0.14.i686
python3-debug-3.7.16-1.amzn2.0.14.i686
python3-debuginfo-3.7.16-1.amzn2.0.14.i686
src:
python3-3.7.16-1.amzn2.0.14.src
x86_64:
python3-3.7.16-1.amzn2.0.14.x86_64
python3-libs-3.7.16-1.amzn2.0.14.x86_64
python3-devel-3.7.16-1.amzn2.0.14.x86_64
python3-tools-3.7.16-1.amzn2.0.14.x86_64
python3-tkinter-3.7.16-1.amzn2.0.14.x86_64
python3-test-3.7.16-1.amzn2.0.14.x86_64
python3-debug-3.7.16-1.amzn2.0.14.x86_64
python3-debuginfo-3.7.16-1.amzn2.0.14.x86_64