CVE-2026-54249Pydantic Ai
Medium 6.8 No auth needed
Follow: this CVE · Pydantic · Pydantic Ai We alert you by email or Slack (account required).
- Priority
- 56
- CVSS 3.1
- 6.8
- EPSS
- —
- Auth required
- No
- Published
- Jul 29, 2026
- Updated
- Aug 4, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-918
- SSVC (CISA)
- Exploitation: none · Automatable: no · Technical impact: partial
- Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:N/A:N
What happens
Pydantic AI is a Python agent framework for building Generative AI applications. In versions 1.65.0 through 1.105.0, and 2.0.0b1 through 2.0.0b5, a client that submits message history to a Pydantic AI UI adapter (such as the Vercel AI adapter) can reference arbitrary files in the application's model-provider or cloud-storage account. While file URL parts are validated against a scheme allowlist, UploadedFile references — which point to a file by provider file ID or cloud-storage URI (e.g. s3://…, gs://…) — were forwarded without validation. Because the provider resolves an UploadedFile using the server-side identity (IAM role, service account, or provider API key) rather than the client's, an attacker can craft message history to make the server read objects from its own account or other tenants, given a referenceable identifier. Exploitation requires a valid file identifier, which is not always unguessable depending on how the application names objects. This issue has been fixed in versions 1.106.0 and 2.0.0b6.
What to do
- Apply the vendor's security update for Pydantic Ai.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| PyPI | pydantic-ai |
≥ 1.65.0 < 1.106.0 |
1.106.0 |
pip install "pydantic-ai>=1.106.0" |
| PyPI | pydantic-ai |
≥ 2.0.0b1 < 2.0.0b6 |
2.0.0b6 |
pip install "pydantic-ai>=2.0.0b6" |
| PyPI | pydantic-ai |
≥ 1.65.0 < 1.106.0 |
1.106.0 |
pip install "pydantic-ai>=1.106.0" |
| PyPI | pydantic-ai |
≥ 2.0.0b1 < 2.0.0b6 |
2.0.0b6 |
pip install "pydantic-ai>=2.0.0b6" |
| PyPI | pydantic-ai-slim |
≥ 1.65.0 < 1.106.0 |
1.106.0 |
pip install "pydantic-ai-slim>=1.106.0" |
| PyPI | pydantic-ai-slim |
≥ 2.0.0b1 < 2.0.0b6 |
2.0.0b6 |
pip install "pydantic-ai-slim>=2.0.0b6" |
| PyPI | pydantic-ai-slim |
≥ 1.65.0 < 1.106.0 |
1.106.0 |
pip install "pydantic-ai-slim>=1.106.0" |
| PyPI | pydantic-ai-slim |
≥ 2.0.0b1 < 2.0.0b6 |
2.0.0b6 |
pip install "pydantic-ai-slim>=2.0.0b6" |
Per OSV / GitHub Advisories (GHSA-h7p7-w5gc-xj3w, PYSEC-2026-3692, PYSEC-2026-3693). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| pydantic | pydantic_ai | ≥ 1.65.0 < 1.105.0 |
| pydantic | pydantic_ai | 2.0.0 |
| pydantic | pydantic_ai | 2.0.0 |
| pydantic | pydantic_ai | 2.0.0 |
| pydantic | pydantic_ai | 2.0.0 |
| pydantic | pydantic_ai | 2.0.0 |
Official sources
References
Links published by the sources. Open them with care.
- github.com Vendor Advisory