diff --git a/Fix-TypeError-Issue-In-patch-CVE-2024-6345.patch b/Fix-TypeError-Issue-In-patch-CVE-2024-6345.patch new file mode 100644 index 0000000000000000000000000000000000000000..eee34bfc767e176e7cf056b1220e0e6b01876fc3 --- /dev/null +++ b/Fix-TypeError-Issue-In-patch-CVE-2024-6345.patch @@ -0,0 +1,33 @@ +From 68e55632734aafee2b80221e6eca24bd1b366609 Mon Sep 17 00:00:00 2001 +From: chenjianhu +Date: Mon, 1 Dec 2025 19:57:43 +0800 +Subject: [PATCH] Fix the TypeError issue in the patch for CVE-2024-6345. + +--- + setuptools/package_index.py | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/setuptools/package_index.py b/setuptools/package_index.py +index 0ee655a..48ca9c9 100644 +--- a/setuptools/package_index.py ++++ b/setuptools/package_index.py +@@ -2,6 +2,7 @@ + import sys + import os + import re ++import subprocess + import shutil + import socket + import base64 +@@ -829,7 +830,7 @@ class PackageIndex(Environment): + pre, sep, post = scheme.partition('+') + # svn and git have their own protocol; hg does not + allowed = set(['svn', 'git'] + ['hg'] * bool(sep)) +- return next(iter(pre & allowed), None) ++ return next(iter({pre} & allowed), None) + + def _download_vcs(self, url, spec_filename): + vcs = self._resolve_vcs(url) +-- +2.43.0 + diff --git a/python-setuptools.spec b/python-setuptools.spec index 17fafafe70354d7491e649c57769d5541a9b1d60..0ca5d10e182f613d510cff12f00444da6f055573 100644 --- a/python-setuptools.spec +++ b/python-setuptools.spec @@ -11,7 +11,7 @@ Name: python-setuptools Version: 44.1.1 -Release: 3 +Release: 4 Summary: Easily build and distribute Python packages License: MIT and (BSD or ASL 2.0) @@ -22,6 +22,7 @@ Patch6000: backport-CVE-2022-40897.patch Patch9000: bugfix-eliminate-random-order-in-metadata.patch Patch9001: backport-CVE-2024-6345.patch +Patch9002: Fix-TypeError-Issue-In-patch-CVE-2024-6345.patch BuildArch: noarch %if %{with python2} @@ -147,6 +148,9 @@ PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=$(pwd) py.test-%{python3_version} --ignore= %changelog +* Wed Dec 3 2025 chenjianhu - 44.1.1-4 +- Fix the TypeError issue in the patch for CVE-2024-6345. + * Mon Jul 15 2024 zhangxianting - 44.1.1-3 - Fix CVE-2024-6345