pydantic-ai-slim is vulnerable to Uncontrolled Resource Consumption
65
Medium Risk
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.
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.
pydantic-ai-slim is vulnerable to Uncontrolled Resource Consumption in versions 1.77.0 - 1.107.6 and 2.0.0 - 2.51.0.
Upgrade the pydantic-ai-slim and/or the pydantic-ai library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

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.