SecurityContext

CVE-2022-40897: PyPA setuptools - Regular Expression Denial of Service

  • Cve: CVE-2022-40897
  • Name: PyPA setuptools - Regular Expression Denial of Service
  • Description: 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.
  • Impact: Remote attackers can cause denial of service by exploiting the ReDoS vulnerability, disrupting package index services.
  • Remediation: Update to setuptools version 65.5.1 or later.
  • Vulnerability type: denial_of_service
  • Vulnerability impact: denial_of_service
  • Requirement type: none
  • Labels source: projectdiscovery
  • Severity: medium
  • Cvss score: 5.9
  • Cvss vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
  • Epss score: 0.02632
  • Epss percentile: 0.85919
  • Assignee: [email protected]
  • Published at: 2022-12-23T00:15:13Z
  • Age in days: 1432
  • Modified at: 2026-06-17T05:02:12Z
  • Patch available: yes
  • Public exploits total: 1
  • References total: 10
  • Products total: 1
  • Oss: yes
  • Projects total: 1
  • Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2022-40897
  • Nvd status: modified
  • Checked, none or zero: known exploited entries, nuclei templates, public exploits capped, rejected by nvd
  • Not known: requirements, hackerone

Cwe

IdName
CWE-1333Inefficient Regular Expression Complexity

Public exploits

UrlSourceAdded date
https://pyup.io/posts/pyup-discovers-redos-vulnerabilities-in-top-python-packages/nvd2022-12-23

References

Same in every row:

  • Source: nvd
UrlTags
https://pyup.io/posts/pyup-discovers-redos-vulnerabilities-in-top-python-packages/Exploit, Patch, Technical Description, Vendor Advisory
https://github.com/pypa/setuptools/commit/43a9c9bfa6aa626ec2a22540bea28d2ca77964bePatch, Third Party Advisory
https://github.com/pypa/setuptools/blob/fe8a98e696241487ba6ac9f91faa38ade939ec5d/setuptools/package_index.py#L200Third Party Advisory
https://github.com/pypa/setuptools/compare/v65.5.0...v65.5.1Release Notes, Third Party Advisory
https://pyup.io/vulnerabilities/CVE-2022-40897/52495/Third Party Advisory
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/ADES3NLOE5QJKBLGNZNI2RGVOSQXA37R/
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/YNA2BAH2ACBZ4TVJZKFLCR7L23BG5C3H/
https://security.netapp.com/advisory/ntap-20230214-0001/
https://security.netapp.com/advisory/ntap-20240621-0006/
https://lists.debian.org/debian-lts-announce/2024/09/msg00018.html

Products

ProductAffectedPlatform boundSourcesUrl
python:setuptools< 65.5.1nonvd/v1/products/python/setuptools

Projects

RepositoryLink kindsIndexedUrl
pypa/setuptoolscommit, compare, fix, issues, packageyes/v1/repositories/pypa/setuptools

Index

  • Repositories: 1277
  • Repositories high signal: 880
  • Packages: 1

Exploitation

  • Public exploit: yes
  • Public exploit count: 1
  • Public exploit first date: 2022-12-23
  • Remote: yes
  • Checked, none or zero: known exploited, known exploited by, exploitation seen, initial access, authentication required
  • Not known: known exploited since, vulncheck known exploited since, nuclei template, initial access since, hackerone reports, exposed hosts