---
id: CVE-2024-6345
aliases:
  - GHSA-cx63-2mw6-8hw5
  - BIT-setuptools-2024-6345
  - PYSEC-2026-1918
title: setuptools vulnerable to Command Injection via package URL
summary: setuptools vulnerable to Command Injection via package URL
severity: high
cvss: 8.8
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'
vendor: setuptools
product: setuptools
ecosystem: pip
affected:
  - setuptools < 70.0.0
patched:
  - setuptools 70.0.0
published: '2024-07-15'
updated: '2026-09-10'
sourceUpdated: '2026-09-10T03:50:16.663495061Z'
source: OSV
sourceUrl: 'https://osv.dev/vulnerability/GHSA-cx63-2mw6-8hw5'
references:
  - url: 'https://nvd.nist.gov/vuln/detail/CVE-2024-6345'
  - url: 'https://github.com/pypa/setuptools/pull/4332'
  - url: >-
      https://github.com/pypa/setuptools/commit/88807c7062788254f654ea8c03427adc859321f0
  - url: 'https://github.com/pypa/setuptools'
  - url: 'https://huntr.com/bounties/d6362117-ad57-4e83-951f-b8141c6e7ca5'
  - url: 'https://lists.debian.org/debian-lts-announce/2024/09/msg00018.html'
tags:
  - osv
  - pip
epss: 0.01939
epssPercentile: 0.79234
ingestedAt: '2026-07-08T18:25:48.607Z'
---

## Overview

A vulnerability in the `package_index` module of pypa/setuptools versions up to 69.1.1 allows for remote code execution via its download functions. These functions, which are used to download packages from URLs provided by users or retrieved from package index servers, are susceptible to code injection. If these functions are exposed to user-controlled inputs, such as package URLs, they can execute arbitrary commands on the system. The issue is fixed in version 70.0.

## Affected packages

- `setuptools < 70.0.0`

## Remediation

Upgrade to a patched release:

- `setuptools 70.0.0`
