Pydantic AI keeps concurrency slots after streams end early
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Denial of service
- Confidentiality · integrity · availability
- None · None · High
- Fix status
- Partial Red Hat: 2 without a fix
Attack profile from CVSS 3.1 · CNA. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-772.
Summary
Pydantic AI from 2.10.0 before 2.53.0 has a flaw in streamed requests made through ConcurrencyLimitedModel or limit_model_concurrency. Shared concurrency slots can stay occupied after a stream ends early, is cancelled, or raises an exception, because the slot belongs to a different task than the one that cleans it up (CWE-772). A remote attacker without privileges or user interaction can eventually exhaust the shared limiter, blocking later requests and causing denial of service.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
Description from the CNA
Pydantic AI is a Python agent framework for building applications and workflows with Generative AI. From 2.10.0 until 2.53.0, streamed requests made through ConcurrencyLimitedModel or limit_model_concurrency can retain shared concurrency slots because anyio.CapacityLimiter associates an acquired slot with the borrowing task while streaming cleanup can run in a different task. Early stream termination, cancellation, consumer exceptions, or complete stream_text() consumption with debounce_by=0.1 can therefore leave capacity occupied, eventually preventing later requests that share the long-lived limiter from proceeding and causing a denial of service. Agent-level max_concurrency and non-streaming model requests are not affected. This issue is fixed in version 2.53.0.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- Yes
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| pydantic | pydantic-ai | 2.10.0 to before 2.53.0 | 2.53.0 | Patch available | CNA |
| pydantic | pydantic-ai-slim | 2.10.0 to before 2.53.0 | 2.53.0 | Patch available | CNA |
| — | pydantic-ai (PyPI) | 2.10.0 to before 2.53.0 | 2.53.0 | Patch available | GHSA-6fqq-452j-qhrp |
| — | pydantic-ai-slim (PyPI) | 2.10.0 to before 2.53.0 | 2.53.0 | Patch available | GHSA-6fqq-452j-qhrp |
- pydantic-ai Vendorpydantic Affected 2.10.0 to before 2.53.0 Fixed in 2.53.0 Patch available CNA
- pydantic-ai-slim Vendorpydantic Affected 2.10.0 to before 2.53.0 Fixed in 2.53.0 Patch available CNA
- pydantic-ai (PyPI) Vendor— Affected 2.10.0 to before 2.53.0 Fixed in 2.53.0 Patch available GHSA-6fqq-452j-qhrp
- pydantic-ai-slim (PyPI) Vendor— Affected 2.10.0 to before 2.53.0 Fixed in 2.53.0 Patch available GHSA-6fqq-452j-qhrp
Remediation
Upgrade pydantic-ai and pydantic-ai-slim to version 2.53.0. The sources list no fixed version for Lightspeed Core or Red Hat Enterprise Linux AI (RHEL AI) 3.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
- Fix · CNA pydantic-ai (pydantic) Fixed in 2.53.0
- Fix · CNA pydantic-ai-slim (pydantic) Fixed in 2.53.0
- Fix · GHSA-6fqq-452j-qhrp pydantic-ai (PyPI) Fixed in 2.53.0 Advisory →
- Fix · GHSA-6fqq-452j-qhrp pydantic-ai-slim (PyPI) Fixed in 2.53.0 Advisory →
Vendor assessments
Red Hat
Red Hat rating: Important. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Lightspeed Core | Affected | No fix yet |
| Red Hat Enterprise Linux AI (RHEL AI) 3 | Affected | No fix yet |
Timeline
- 2026-10-08 Threatist record created from CVE-2026-107286
- 2026-10-09 Alias added: GHSA-6fqq-452j-qhrp
- 2026-10-09 Fix available: PyPI/[email protected], PyPI/[email protected] · GHSA-6fqq-452j-qhrp
- 2026-10-09 CVSS score added · GHSA-6fqq-452j-qhrp
- 2026-10-09 Weakness changed · GHSA-6fqq-452j-qhrp
- 2026-10-09 6 new references · GHSA-6fqq-452j-qhrp
- 2026-10-09 Affected versions changed · Red Hat
- 2026-10-09 CVSS score added · Red Hat
References
Patch 3
Advisory 2
More Pydantic Ai vulnerabilities
- TI-2026-20687 Pydantic AI Affected by Server-Side Request Forgery (SSRF) in URL Download Handling CVSS 3.1HIGH 8.6
- TI-2026-46990 Incorrect authorization in pydantic-ai CVSS 3.1MEDIUM 6.5
- TI-2026-69610 Cross-site requests run agent tools in pydantic-ai web chat CVSS 3.1HIGH 7.6
- TI-2026-20740 Pydantic AI affected by Stored XSS via Path Traversal in Web UI CDN URL CVSS 3.1HIGH 7.1
- TI-2026-69617 Pydantic AI blocklist bypass via IPv6 zone identifier allows SSRF CVSS 3.1MEDIUM 6.8
- TI-2026-39151 Server-side request forgery in pydantic-ai CVSS 3.1MEDIUM 6.8
Sources
- CVE-2026-107286 · CVE Program
- CVE-2026-107286 · NVD
- FIRST EPSS
- GHSA-6fqq-452j-qhrp · GitHub Advisory Database · CC BY 4.0
- CVE-2026-107286 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences