Vulnerabilities

Vulnerability · CVE-2026-5366

Prefect has Git Flag Injection via commit_sha and directories Parameters Leading to Remote Code Execution (RCE)

Published Jun 20, 2026 · catalog updated Nov 3, 2026 · Prefect has Git Flag

Last checked Nov 5, 2026. A connected source was read within the last 7 days.

Check if you run it

No confirmed exploitation is on record for CVE-2026-5366. EPSS is 1.03%. Act only if a listed version of Prefect has Git Flag is installed.

Gaps on this record

  • The stored product name is a package slug. The name on this page is taken from the title (Prefect has Git Flag).
  • No vendor fix or required action is stored. Compare the linked advisory before you change production.
Severity
Critical9.9
Known exploitation
Not in CISA/VulnCheck KEV
EPSS
1.03%
Remediation
Advisory link
Affected products
PyPI prefect

Prefect versions 3.1.11 through 3.6.24 are vulnerable to remote code execution due to improper handling of user-controlled input in the storage class. The parameter, which is passed to git commands, lacks validation and does not include a separator to distinguish user input from git flags. This allows attackers to inject arbitrary git flags, such as , enabling execution of external programs. Additionally, the parameter can be exploited to inject git flags during sparse-checkout operations. These vulnerabilities allow any user with deployment creation permissions to execute arbitrary commands on worker machines, compromising shared work pools in multi-tenant environments.

Are you affected?

Enter the version you run. The result uses only the ranges stored on this record.

The check returns affected, not affected, or incomplete. It does not guess a version that is missing from the record.

  • PyPI prefect3.1.11 → 3.6.25

How to fix CVE-2026-5366

  • Upgrade

    CVE-2026-5366 lists a fix boundary at 3.6.25. Compare the installed build with that boundary before you change production.

  • Version check

    Seen in 3.1.11 → 3.6.25

  • Advisory

    Open the cve_org record and follow its fix.

  • Official advisories

What to do

Three questions, each answered from this record only. Confirm the vendor advisory before you patch.

Should you patch?

No confirmed exploitation is on record for CVE-2026-5366. EPSS is 1.03%. Act only if a listed version of Prefect has Git Flag is installed.

Which versions are affected?

Compare what you have installed with 3.1.11 → 3.6.25. Compare the installed version with the linked vendor advisory before you change production.

What should an analyst verify?

CWE-94: Code Injection. EPSS 1.03%. There is no CISA KEV listing. No Exploit-DB or Metasploit reference is linked. Use the source links for the original advisory.

Code

The project this record applies to. Exploit listings stay in References.

Timeline

Detection, updates, and resolution for this record.

  1. Jun 20, 2026 · PyPA Advisory Database

    Detected

    Prefect versions 3.1.11 through 3.6.24 are vulnerable to remote code execution due to improper handling of user-controlled input in the storage class. The parameter, which is passed to git commands, lacks validation and does not include a separator to distinguish user input from git flags. This allows attackers to inject arbitrary git flags, such as , enabling execution of external programs. Addit

  2. Nov 3, 2026 · PyPA Advisory Database

    Fix available

    prefect fixed in 3.6.25

  3. Nov 3, 2026 · PyPA Advisory Database

    Fix available

    prefect fixed in 3.6.25

  4. Nov 3, 2026 · PyPA Advisory Database

    Updated

    Prefect versions 3.1.11 through 3.6.24 are vulnerable to remote code execution due to improper handling of user-controlled input in the storage class. The parameter, which is passed to git commands, lacks validation and does not include a separator to distinguish user input from git flags. This allows attackers to inject arbitrary git flags, such as , enabling execution of external programs. Addit

Sources

  • CVE.orgVulnerability recordCVE-2026-5366

    Official CVE identifier

    cve.org
  • PyPA Advisory DatabasePackage advisoryGHSA-7pm4-56h2-5rxr

    Prefect has Git Flag Injection via commit_sha and directories Parameters Leading to Remote Code Execution (RCE)

    osv.dev

References

Freshness

Last verified in this catalog Nov 4, 2026. Significant claims (KEV, EPSS, CVSS, affected ranges) come from the source rows above — open the original publisher for the authoritative advisory.

  • PyPA Advisory DatabaseNov 5, 2026
  • CVE.orgNov 4, 2026