返回全部动态

PydanticAI v2.30.0 发布:修复 DNS 重绑定漏洞并新增 Gemini 3.7 Flash 支持

原标题:v2.30.0 (2026-08-13)

PydanticAI Releases一手来源产品发布质量 76

AI 摘要

PydanticAI 发布 v2.30.0 版本,修复了本地开发 Web 聊天界面(Agent.to_web() 和 clai web)的 DNS 重绑定安全漏洞,通过默认验证 Host 头为 localhost/loopback/LAN 地址,并新增 allowed_hosts 设置供真实域名部署时使用。新功能包括支持 OpenRouter 的 web_search、新增 gemini-3.7-flash 模型、在 XaiProvider 上暴露 gRPC metadata,以及多项 bug 修复。

以上摘要由 AI 生成,可能存在误差。事实请以原文为准。

正文节选

<!-- Release notes generated using configuration in .github/release.yml at main --> ## What's Changed ### 🛡️ Security * [GHSA-q2xc-rrxj-58x9](https://github.com/pydantic/pydantic-ai/security/advisories/GHSA-q2xc-rrxj-58x9): the local dev web chat UI (`Agent.to_web()`, `clai web`) didn't validate the `Host` header, so DNS rebinding from a website you visit could reach it and run the served agent with your local process's tools and credentials. Fixed in `pydantic-ai`/`pydantic-ai-slim` 2.30.0 by


发布时间:2026-08-14 10:57
抓取时间:2026-08-14 11:38
来源机构:Pydantic
阅读原文github.com