一、 漏洞 CVE-2024-3220 基础信息
漏洞信息
                                        # 默认的mimetype已知文件在Windows下可写

## 概述
CPython标准库模块“mimetypes”中存在一个缺陷,该缺陷在Windows系统上允许其他用户创建无效文件,导致Python运行时启动时出现`MemoryError`或使文件扩展名解释为不正确的文件类型。

## 影响版本
未明确指出具体版本,但影响所有在Windows上运行的CPython版本。

## 细节
在Windows上,Linux和macOS平台的默认已知文件位置(如“/etc/mime.types”)也被使用,导致它们成为用户可写的位置(如“C:\etc\mime.types”)。这允许其他用户创建可能导致`MemoryError`的无效文件,或使文件扩展名解释错误。

## 影响
该缺陷可能导致Python在启动时出现`MemoryError`,或者文件扩展名被错误解释。建议在Windows平台上使用`mimetypes.init([])`来避免使用默认的文件位置列表,从而规避该问题。
                                        
提示
尽管我们采用了先进的大模型技术,但其输出仍可能包含不准确或过时的信息。
神龙会尽力确保数据准确,但也请结合实际情况进行甄别与判断。
神龙祝您一切顺利!
漏洞标题
Default mimetype known files writeable on Windows
来源:美国国家漏洞数据库 NVD
漏洞描述信息
There is a defect in the CPython standard library module “mimetypes” where on Windows the default list of known file locations are writable meaning other users can create invalid files to cause MemoryError to be raised on Python runtime startup or have file extensions be interpreted as the incorrect file type. This defect is caused by the default locations of Linux and macOS platforms (such as “/etc/mime.types”) also being used on Windows, where they are user-writable locations (“C:\etc\mime.types”). To work-around this issue a user can call mimetypes.init() with an empty list (“[]”) on Windows platforms to avoid using the default list of known file locations.
来源:美国国家漏洞数据库 NVD
CVSS信息
N/A
来源:美国国家漏洞数据库 NVD
漏洞类别
不可信的搜索路径
来源:美国国家漏洞数据库 NVD
漏洞标题
CPython 安全漏洞
来源:中国国家信息安全漏洞库 CNNVD
漏洞描述信息
CPython是Python基金会的一个用C语言实现的Python解释器。 CPython存在安全漏洞,该漏洞源于在Windows平台上默认使用用户可写的文件路径,可能导致内存错误或文件类型误判。
来源:中国国家信息安全漏洞库 CNNVD
CVSS信息
N/A
来源:中国国家信息安全漏洞库 CNNVD
漏洞类别
其他
来源:中国国家信息安全漏洞库 CNNVD
二、漏洞 CVE-2024-3220 的公开POC
# POC 描述 源链接 神龙链接
三、漏洞 CVE-2024-3220 的情报信息