ADVISORIES

Vulnerability

CVE-2022-40897

Python Packaging Authority (PyPA) setuptools before 65.5.1 allows remote attackers to cause a denial of service via HTML in a crafted package or custom PackageIndex page. There is a Regular Expression Denial of Service (ReDoS) in package_index.py.

47 advisories report this vulnerability, across 13 ecosystems.

Advisories

  • ALAS2-2023-1979

    Amazon Linux 2 2017.12 - ALAS2-2023-1979: medium priority package update for python2-setuptools

    Medium CVE-2022-40897 Amazon Linux Updated 7 March 2023
  • ALAS2-2023-2196

    Amazon Linux 2 2017.12 - ALAS2-2023-2196: medium priority package update for python-setuptools

    Medium CVE-2022-40897 Amazon Linux Updated 8 August 2023
  • ALAS2023-2023-245

    Amazon Linux 2023 - ALAS2023-2023-245: Medium priority package update for python-setuptools

    Medium CVE-2022-40897 Amazon Linux Updated 20 July 2023
  • ALSA-2023:0835

    Moderate: python-setuptools security update

    CVE-2022-40897 AlmaLinux Updated 29 October 2026
  • ALSA-2023:0952

    Moderate: python-setuptools security update

    CVE-2022-40897 AlmaLinux Updated 29 October 2026
  • ALSA-2024:2985

    Moderate: python39:3.9 and python39-devel:3.9 security update

    CVE-2022-40897CVE-2023-23931CVE-2023-27043CVE-2023-43804 AlmaLinux Updated 29 October 2026
  • ALSA-2024:2987

    Moderate: python27:2.7 security update

    CVE-2022-40897CVE-2022-48560CVE-2022-48565CVE-2023-43804 AlmaLinux Updated 29 October 2026
  • AZL-60207

    CVE-2022-40897 affecting package python3 for versions less than 3.9.19-11

    CVE-2022-40897 Azure Linux Updated 21 April 2026
  • CGA-27cw-f7ww-w9rf
    CVE-2022-40897 Chainguard Updated 11 September 2026
  • CGA-28mc-m4pc-w6fx
    CVE-2022-40897 Chainguard Updated 11 September 2026
  • CGA-5rp6-cp37-v856
    CVE-2022-40897 Chainguard Updated 11 September 2026
  • CGA-qgq8-6qqj-99gr
    CVE-2022-40897 Chainguard Updated 11 September 2026
  • DEBIAN-CVE-2022-40897

    Python Packaging Authority (PyPA) setuptools before 65.5.1 allows remote attackers to cause a denial of service via HTML in a crafted package or custom PackageIndex page. There is a Regular Expression Denial of Service…

    CVE-2022-40897 Debian Updated 20 November 2026
  • DLA-3876-1

    setuptools - security update

    CVE-2022-40897CVE-2024-6345 Debian Updated 20 November 2026
  • ELSA-2023-0835

    ELSA-2023-0835: python-setuptools security update (MODERATE)

    Moderate CVE-2022-40897 Oracle Linux Updated 22 February 2023
  • ELSA-2023-0952

    ELSA-2023-0952: python-setuptools security update (MODERATE)

    Moderate CVE-2022-40897 Oracle Linux Updated 28 February 2023
  • ELSA-2023-12348

    ELSA-2023-12348: python3-setuptools security update (IMPORTANT)

    Important CVE-2022-40897 Oracle Linux Updated 23 May 2023
  • ELSA-2024-2985

    ELSA-2024-2985: python39:3.9 and python39-devel:3.9 security update (MODERATE)

    Moderate CVE-2022-40897CVE-2023-23931CVE-2023-27043CVE-2023-43804 Oracle Linux Updated 24 May 2024
  • ELSA-2024-2987

    ELSA-2024-2987: python27:2.7 security update (MODERATE)

    Moderate CVE-2022-40897CVE-2022-48560CVE-2022-48565CVE-2023-43804 Oracle Linux Updated 24 May 2024
  • GHSA-r9hx-vwmv-q579

    pypa/setuptools vulnerable to Regular Expression Denial of Service (ReDoS)

    High CVE-2022-40897 PyPI Updated 7 August 2026
  • OESA-2023-1004

    python-setuptools security update

    High CVE-2022-40897 openEuler Updated 18 August 2026
  • PYSEC-2022-43012

    Python Packaging Authority (PyPA) setuptools before 65.5.1 allows remote attackers to cause a denial of service via HTML in a crafted package or custom PackageIndex page. There is a Regular Expression Denial of Service…

    CVE-2022-40897 PyPI Updated 10 June 2026
  • RHSA-2023:0835

    Red Hat Security Advisory: python-setuptools security update

    CVE-2022-40897 Red Hat Updated 13 November 2026
  • RHSA-2023:0952

    Red Hat Security Advisory: python-setuptools security update

    CVE-2022-40897 Red Hat Updated 13 November 2026
  • RHSA-2023:6793

    Red Hat Security Advisory: rh-python38-python security update

    CVE-2007-4559CVE-2022-40897CVE-2022-40898CVE-2022-45061 Red Hat Updated 23 November 2026
  • RHSA-2023:7395

    Red Hat Security Advisory: python-setuptools security update

    CVE-2022-40897 Red Hat Updated 13 November 2026
  • RHSA-2024:2985

    Red Hat Security Advisory: python39:3.9 and python39-devel:3.9 security update

    CVE-2022-40897CVE-2023-23931CVE-2023-27043CVE-2023-43804 Red Hat Updated 13 November 2026
  • RHSA-2024:2987

    Red Hat Security Advisory: python27:2.7 security update

    CVE-2022-40897CVE-2022-48560CVE-2022-48565CVE-2023-43804 Red Hat Updated 23 November 2026
  • RHSA-2024:4421

    Red Hat Security Advisory: python39:3.9 and python39-devel:3.9 security update

    CVE-2022-40897 Red Hat Updated 13 November 2026
  • RHSA-2024:6915

    Red Hat Security Advisory: python39:3.9 security update

    CVE-2022-40897CVE-2024-6923 Red Hat Updated 13 November 2026
  • RHVEX-CVE-2022-40897

    pypa-setuptools: Regular Expression Denial of Service (ReDoS) in package_index.py

    Moderate CVE-2022-40897 Red Hat Updated 5 November 2026
  • RLSA-2023:0835

    Moderate: python-setuptools security update

    CVE-2022-40897 Rocky Linux Updated 4 February 2026
  • RLSA-2023:0952

    Moderate: python-setuptools security update

    CVE-2022-40897 Rocky Linux Updated 5 February 2026
  • RLSA-2024:2985

    Moderate: python39:3.9 and python39-devel:3.9 security update

    CVE-2022-40897CVE-2023-23931CVE-2023-27043CVE-2023-43804 Rocky Linux Updated 4 February 2026
  • RLSA-2024:2987

    Moderate: python27:2.7 security update

    CVE-2022-40897CVE-2022-48560CVE-2022-48565CVE-2023-43804 Rocky Linux Updated 7 May 2025
  • SUSE-SU-2023:0091-1

    Security update for python310-setuptools

    CVE-2022-40897 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2023:0093-1

    Security update for python-setuptools

    CVE-2022-40897 SUSE Updated 4 February 2026
  • SUSE-SU-2023:0094-1

    Security update for python36-setuptools

    CVE-2022-40897 SUSE Updated 4 February 2026
  • SUSE-SU-2023:0159-1

    Security update for python-setuptools

    CVE-2022-40897 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2023:0202-1

    Security update for python39-setuptools

    CVE-2022-40897 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2023:0223-1

    Security update for python-setuptools

    CVE-2022-40897 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2023:0402-1

    Security update for python-setuptools

    CVE-2022-40897 SUSE Updated 4 February 2026
  • SUSE-SU-2023:0403-1

    Security update for python-setuptools

    CVE-2022-40897 SUSE Updated 4 February 2026
  • SUSE-SU-2023:4517-1

    Security update for python3-setuptools

    CVE-2022-40897 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2024:2435-1

    Security update for python3-setuptools

    CVE-2022-40897 SUSE Updated 4 February 2026
  • UBUNTU-CVE-2022-40897

    Python Packaging Authority (PyPA) setuptools before 65.5.1 allows remote attackers to cause a denial of service via HTML in a crafted package or custom PackageIndex page. There is a Regular Expression Denial of Service…

    CVE-2022-40897 Ubuntu Updated 4 February 2026
  • USN-5817-1

    python-setuptools, setuptools vulnerability

    CVE-2022-40897 Ubuntu Updated 29 June 2026

References