Quick answers
- Is CVE-2026-5366 exploited in the wild?
- No. Junglewise Threat Intelligence has no report of CVE-2026-5366 being exploited in the wild.
- How severe is CVE-2026-5366?
- Critical severity, with a CVSS score of 9.9, published 20 June 2026.
- Which products and versions are affected?
- prefect (PyPI) >= 3.1.11, < 3.6.25, ECOSYSTEM:introduced=3.1.11,fixed=3.6.25.
- Is there a fix for CVE-2026-5366?
- Yes. prefect (PyPI): upgrade to 3.6.25 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
- How is CVE-2026-5366 attacked?
- It is attacked over the network, in a software library.
- Am I affected by CVE-2026-5366?
- Check whether you run prefect (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.
How to fix
- prefect (PyPI): upgrade to 3.6.25 or later
pip install "prefect>=3.6.25"
Technical details
A remote code execution vulnerability exists in Prefect's `GitRepository` storage class due to improper validation of the `commit_sha` and `directories` parameters. These parameters are passed directly to git commands without a `--` separator, allowing an attacker to inject git flags such as `--upload-pack`. By providing a malicious flag, an authenticated user with deployment creation permissions can trigger the execution of arbitrary external programs on the worker node. This is particularly impactful in multi-tenant environments where shared work pools can be compromised. The vulnerability is classified as CWE-94 (Improper Control of Generation of Code).
Affected products
- PrefectHQ Prefect 3.6.23 and earlier
Identifiers
- CVE-2026-5366
- GHSA-7pm4-56h2-5rxr
Timeline
- 2026-06-20: disclosed
- 2026-06-20: advisory