Description
The remote host is affected by the vulnerability described in GLSA-202405-01 (Python, PyPy3: Multiple Vulnerabilities)
- An issue was found in CPython 3.12.0 `subprocess` module on POSIX platforms. The issue was fixed in CPython 3.12.1 and does not affect other stable releases. When using the `extra_groups=` parameter with an empty list as a value (ie `extra_groups=[]`) the logic regressed to not call `setgroups(0, NULL)` before calling `exec()`, thus not dropping the original processes' groups before starting the new process. There is no issue when the parameter isn't used or when any value is used besides an empty list. This issue only impacts CPython processes run with sufficient privilege to make the `setgroups` system call (typically `root`). (CVE-2023-6507)
- An issue was found in the CPython `tempfile.TemporaryDirectory` class affecting versions 3.12.1, 3.11.7, 3.10.13, 3.9.18, and 3.8.18 and prior. The tempfile.TemporaryDirectory class would dereference symlinks during cleanup of permissions-related errors. This means users which can run privileged programs are potentially able to modify permissions of files referenced by symlinks in some circumstances.
(CVE-2023-6597)
- An issue in the urllib.parse component of Python before 3.11.4 allows attackers to bypass blocklisting methods by supplying a URL that starts with blank characters. (CVE-2023-24329)
- An issue was discovered in Python before 3.8.18, 3.9.x before 3.9.18, 3.10.x before 3.10.13, and 3.11.x before 3.11.5. It primarily affects servers (such as HTTP servers) that use TLS client authentication. If a TLS server-side socket is created, receives data into the socket buffer, and then is closed quickly, there is a brief window where the SSLSocket instance will detect the socket as not connected and won't initiate a handshake, but buffered data will still be readable from the socket buffer. This data will not be authenticated if the server-side TLS peer is expecting client certificate authentication, and is indistinguishable from valid TLS stream data. Data is limited in size to the amount that will fit in the buffer. (The TLS connection cannot directly be used for data exfiltration because the vulnerable code path requires that the connection be closed on initialization of the SSLSocket.) (CVE-2023-40217)
- An issue was discovered in Python 3.11 through 3.11.4. If a path containing '\0' bytes is passed to os.path.normpath(), the path will be truncated unexpectedly at the first '\0' byte. There are plausible cases in which an application would have rejected a filename for security reasons in Python 3.10.x or earlier, but that filename is no longer rejected in Python 3.11.x. (CVE-2023-41105)
- An issue was found in the CPython `zipfile` module affecting versions 3.12.1, 3.11.7, 3.10.13, 3.9.18, and 3.8.18 and prior. The zipfile module is vulnerable to quoted-overlap zip-bombs which exploit the zip format to create a zip-bomb with a high compression ratio. The fixed versions of CPython makes the zipfile module reject zip archives which overlap entries in the archive. (CVE-2024-0450)
Note that Nessus has not tested for these issues but has instead relied only on the application's self-reported version number.
Solution
All Python, PyPy3 users should upgrade to the latest version:
# emerge --sync # emerge --ask --oneshot --verbose >=dev-lang/python-3.12.1:3.12 # emerge --ask --oneshot --verbose >=dev-lang/python-3.11.9:3.11 # emerge --ask --oneshot --verbose >=dev-lang/python-3.10.14:3.10 # emerge --ask --oneshot --verbose >=dev-lang/python-3.9.19:3.9 # emerge --ask --oneshot --verbose >=dev-lang/python-3.8.19:3.8 # emerge --ask --oneshot --verbose >=dev-python/pypy3-7.3.16 # emerge --ask --oneshot --verbose >=dev-python/pypy3_10-7.3.16 # emerge --ask --oneshot --verbose >=dev-python/pypy3_9-7.3.16
Plugin Details
File Name: gentoo_GLSA-202405-01.nasl
Supported Sensors: Nessus
Risk Information
Vector: CVSS2#AV:N/AC:L/Au:N/C:N/I:C/A:N
Vector: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
Temporal Vector: CVSS:3.0/E:P/RL:O/RC:C
Vulnerability Information
CPE: cpe:/o:gentoo:linux, p-cpe:/a:gentoo:linux:python, p-cpe:/a:gentoo:linux:pypy3_10, p-cpe:/a:gentoo:linux:pypy3, p-cpe:/a:gentoo:linux:pypy3_9
Required KB Items: Host/local_checks_enabled, Host/Gentoo/release, Host/Gentoo/qpkg-list
Exploit Ease: Exploits are available
Patch Publication Date: 5/4/2024
Vulnerability Publication Date: 2/17/2023