CVE-2026-107290: Pydantic AI Event Loop Blocked by Quadratic Title Extraction in web_fetch

pydantic-ai Updated 08 Oct 2026

Summary

08/10/2026
Yes i
Moderate
6.5

CVE-2026-107290: Pydantic AI: Event loop blocked by quadratic title extraction in web_fetch. Affects pydantic-ai across 2 version ranges.

>= 1.77.0, < 1.107.6 >= 2.0.0b1, < 2.44.0

Fixed in 1.107.6 or 2.44.0, depending on the release line you run. How to fix ↓

Also tracked for

The same CVE-2026-107290 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

Pydantic AI is a Python library designed for data validation and settings management using Python type annotations. It provides a powerful and flexible way to define data models and validate data, making it widely used in applications that require data integrity. However, a recent vulnerability has been identified in its local web-fetch tool, which can lead to significant performance issues when processing server-controlled inputs.

Vulnerability Detail

The vulnerability arises from the local web-fetch tool's handling of responses, where the processing time grows quadratically with the size of certain inputs. This includes decoding the response body, extracting the page title using a backtracking regular expression, and converting HTML to markdown. An attacker can exploit this by sending a large response, causing the event loop to be blocked for an extended period, which stalls other coroutines and affects application availability. The issue is exacerbated by the use of inefficient regex patterns and the potential for deep recursion in HTML-to-markdown conversion, leading to application crashes.

How To Fix

Latest published version: 2.60.0 as of 23 Oct 2026

pip install --upgrade "pydantic-ai==2.60.0"

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • >= 1.77.0, < 1.107.6 1.107.6
    pip install --upgrade "pydantic-ai==1.107.6"
  • >= 2.0.0b1, < 2.44.0 2.44.0
    pip install --upgrade "pydantic-ai==2.44.0"

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

As a temporary workaround, avoid exposing the local web-fetch tool to untrusted inputs. Implement strict input validation and limit the size of responses that can be processed by the tool.

Conclusion

The CVE-2026-107290 vulnerability in Pydantic AI poses a significant risk to applications that utilize the local web-fetch tool with untrusted inputs. By upgrading to the patched versions and implementing proper input validation, developers can mitigate the risks associated with this vulnerability.

See every vulnerability recorded for pydantic-ai →

Share this vulnerability

FAQ

The vulnerability is an availability issue caused by quadratic processing time in the web-fetch tool, which can be exploited by sending large server-controlled responses.

If your application uses the local web-fetch tool or the WebFetch capability's local fallback and processes untrusted inputs, it may be affected by this vulnerability.

Exploiting this vulnerability can lead to significant delays in processing requests, affecting the overall performance and availability of your application.

Yes, you can use Vulert to monitor and alert in real-time for open-source vulnerabilities in your software. It requires only the Pipfile.lock to function.

Yes, you can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without any signup.

Related vulnerabilities

Recent vulnerabilities recorded for pydantic-ai.

How To Fix

Latest published version: 2.60.0 as of 23 Oct 2026

pip install --upgrade "pydantic-ai==2.60.0"

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • >= 1.77.0, < 1.107.6 1.107.6
    pip install --upgrade "pydantic-ai==1.107.6"
  • >= 2.0.0b1, < 2.44.0 2.44.0
    pip install --upgrade "pydantic-ai==2.44.0"

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback