CVE-2026-133161
Published:November 19, 2026
Updated:November 23, 2026
Summary ui
With "strip_ansi=True", Pydantic AI Harness's "ToolOutputLimits" capability removes ANSI escape sequences from tool output with a pattern that takes time quadratic in the length of a line. A tool result of a few hundred kilobytes, crafted with many unterminated escape sequences, can occupy the event loop for tens of seconds to minutes, delaying every other request and agent run in the process.
Details
This affects applications that set "strip_ansi=True" on "ToolOutputLimits" (named "OverflowingToolOutput" before 0.13.0) and run tools whose output an attacker can influence, such as shell commands, file reads, fetched pages or MCP servers. Stripping runs on the event loop before the capability reduces the output, so its own size limits do not bound it.
The assumed attacker can place text in content a tool returns.
Mitigation
Upgrade "pydantic-ai-harness" to 0.70.0 or later. Until then, leave "strip_ansi" at its default, "False".
On Pydantic AI v1, the harness cannot be upgraded past 0.4.0. Upgrade to Pydantic AI v2 and "pydantic-ai-harness" 0.70.0, or leave "strip_ansi" off.
Affected Packages
pydantic-ai-harness (CONDA):
Affected version(s) >=0.4.0 <0.70.0Fix Suggestion:
Update to version 0.70.0https://github.com/pydantic/pydantic-ai.git (GITHUB):
Affected version(s) >=v2.52.0 <v2.70.0Fix Suggestion:
Update to version v2.70.0pydantic-ai-harness (PYTHON):
Affected version(s) >=0.4.0 <0.70.0Fix Suggestion:
Update to version 0.70.0Additional Notes
The description of this vulnerability differs from MITRE.
Related Resources (1)
Do you need more information?
Contact UsCVSS v4
Base Score:
8.7
Attack Vector
NETWORK
Attack Complexity
LOW
Attack Requirements
NONE
Privileges Required
NONE
User Interaction
NONE
Vulnerable System Confidentiality
NONE
Vulnerable System Integrity
NONE
Vulnerable System Availability
HIGH
Subsequent System Confidentiality
NONE
Subsequent System Integrity
NONE
Subsequent System Availability
NONE
CVSS v3
Base Score:
7.5
Attack Vector
NETWORK
Attack Complexity
LOW
Privileges Required
NONE
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Weakness Type (CWE)
Inefficient Regular Expression Complexity
EPSS
Base Score:
0.41