低危 pydantic_project pydantic 不可达退出条件的循环(无限循环)
CVE编号
CVE-2021-29510利用情况
暂无补丁情况
官方补丁披露时间
2021-05-14漏洞描述
Pydantic is a data validation and settings management using Python type hinting. In affected versions passing either `'infinity'`, `'inf'` or `float('inf')` (or their negatives) to `datetime` or `date` fields causes validation to run forever with 100% CPU usage (on one CPU). Pydantic has been patched with fixes available in the following versions: v1.8.2, v1.7.4, v1.6.2. All these versions are available on pypi(https://pypi.org/project/pydantic/#history), and will be available on conda-forge(https://anaconda.org/conda-forge/pydantic) soon. See the changelog(https://pydantic-docs.helpmanual.io/) for details. If you absolutely can't upgrade, you can work around this risk using a validator(https://pydantic-docs.helpmanual.io/usage/validators/) to catch these values. This is not an ideal solution (in particular you'll need a slightly different function for datetimes), instead of a hack like this you should upgrade pydantic. If you are not using v1.8.x, v1.7.x or v1.6.x and are unable to upgrade to a fixed version of pydantic, please create an issue at https://github.com/samuelcolvin/pydantic/issues requesting a back-port, and we will endeavour to release a patch for earlier versions of pydantic.解决建议
建议您更新当前系统或软件至最新版,完成漏洞的修复。受影响软件情况
# | 类型 | 厂商 | 产品 | 版本 | 影响面 | ||||
1 | |||||||||
---|---|---|---|---|---|---|---|---|---|
运行在以下环境 | |||||||||
应用 | pydantic_project | pydantic | * | Up to (excluding) 1.6.2 | |||||
运行在以下环境 | |||||||||
应用 | pydantic_project | pydantic | * | From (including) 1.7 | Up to (excluding) 1.7.4 | ||||
运行在以下环境 | |||||||||
应用 | pydantic_project | pydantic | * | From (including) 1.8 | Up to (excluding) 1.8.2 | ||||
运行在以下环境 | |||||||||
系统 | debian_11 | pydantic | * | Up to (excluding) 1.7.4-1 | |||||
运行在以下环境 | |||||||||
系统 | debian_12 | pydantic | * | Up to (excluding) 1.7.4-1 | |||||
运行在以下环境 | |||||||||
系统 | debian_sid | pydantic | * | Up to (excluding) 1.7.4-1 | |||||
运行在以下环境 | |||||||||
系统 | fedora_33 | python-pydantic | * | Up to (excluding) 1.6.2-1.fc33 | |||||
运行在以下环境 | |||||||||
系统 | fedora_34 | python-pydantic | * | Up to (excluding) 0.4.3-2.fc34 | |||||
- 攻击路径 本地
- 攻击复杂度 容易
- 权限要求 无需权限
- 影响范围 有限影响
- EXP成熟度 N/A
- 补丁情况 官方补丁
- 数据保密性 无影响
- 数据完整性 无影响
- 服务器危害 DoS
- 全网数量 N/A
CWE-ID | 漏洞类型 |
CWE-835 | 不可达退出条件的循环(无限循环) |
Exp相关链接

版权声明
本站原创文章转载请注明文章出处及链接,谢谢合作!
评论