Advisory

PYSEC-2026-2501

Also known as: CVE-2026-31246, GHSA-m85w-whwh-qvfx

Summary

GPT-Pilot contains a command injection vulnerability in the Executor.run() method

Details

GPT-Pilot thru commit 0819827ce20346ef5f25b3fe29293cb448840565 (2025-09-03) contains a command injection vulnerability (CWE-78) in the Executor.run() method. During project execution, when the system prompts the user to confirm or modify a command to be run, it accepts free-text input without proper validation. The user-supplied input is directly passed to asyncio.create_subprocess_shell() for execution. This allows an attacker to replace the intended command with arbitrary shell commands, leading to remote code execution with the privileges of the GPT-Pilot process.

Severity

Medium Basis: CVSS v3 score 6.5, vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N

Dates

Published
2026-07-13 15:15 UTC
Modified
2026-07-13 16:31 UTC

Affected packages and fixes

gpt-pilot

PyPI · All systems

Affected

  • introduced 0, last affected 0.0.10 (ecosystem)

Fixed versions

None listed

Fix

No fixed version is listed.

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: PyPA Advisory Database · CC BY 4.0

Sources & licences