pydantic-ai-slim is vulnerable to Uncontrolled Resource Consumption
65
CVE Score
Medium
Uncontrolled Resource Consumption
The local web_fetch tool converts fetched HTML to Markdown by processing nested block elements and reprocessing each descendant's accumulated text at every level, so a small page with deep nesting such as repeated blockquotes, list items, or definition items expands into a very large intermediate string. Fetching untrusted HTML with this structure consumes excessive CPU and memory and stalls other work in the process, and on older releases the conversion ran directly on the event loop, leading to denial of service. The response body limit only bounds downloaded bytes and the returned content limit applies after conversion, so neither bounds the cost of the conversion itself. The fix adds conversion cost, text scan, and nesting depth limits that abort the conversion once the work budgets are exceeded.
Upgrade the pydantic-ai-slim and/or the pydantic-ai library to the patch version.
You are affected if you are using a version that falls within the vulnerable range and you use the local web_fetch tool to convert untrusted HTML pages to Markdown.
1.77.0 - 1.107.6
Fixed in 1.107.72.0.0 - 2.51.0
Fixed in 2.52.0pydantic-ai-slim is vulnerable to Uncontrolled Resource Consumption in versions 1.77.0 - 1.107.6 and 2.0.0 - 2.51.0.
Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.
No credit card required | Scan results in 32 seconds.
I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.