Time-of-check Time-of-use (TOCTOU) Race Condition Affecting prefect package, versions [,3.6.28.dev2)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.03% (8th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Time-of-check Time-of-use (TOCTOU) Race Condition vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PYTHON-PREFECT-16383760
  • published4 May 2026
  • disclosed4 May 2026
  • creditnedlir

Introduced: 4 May 2026

NewCVE-2026-7724  (opens in a new tab)
CWE-367  (opens in a new tab)
CWE-918  (opens in a new tab)

How to fix?

Upgrade prefect to version 3.6.28.dev2 or higher.

Overview

prefect is a Prefect is a new workflow management system, designed for modern infrastructure and powered by the open-source Prefect Core workflow engine. Users organize Tasks into Flows, and Prefect takes care of the rest.

Affected versions of this package are vulnerable to Time-of-check Time-of-use (TOCTOU) Race Condition in the validate_restricted_url() function of the Webhook and CustomWebhookNotificationBlock components, which enables DNS rebinding attacks. When allow_private_urls is set to False, an attacker can bypass intended URL restrictions by returning a public IP address first, which passes validation, and then a private one at the time of the actual connection.

CVSS Base Scores

version 4.0
version 3.1