漏洞信息
尽管我们使用了先进的大模型技术,但其输出仍可能包含不准确或过时的信息。神龙努力确保数据的准确性,但请您根据实际情况进行核实和判断。
Vulnerability Title
Hugging Face Transformers library writes remote code to disk prior to consent check
Vulnerability Description
A vulnerability in Hugging Face Transformers (versions 4.57.0 to 5.16.1) allows remote Python files to be written to local disk without user consent when using GenerativePreTrainedModel.load_custom_generate(). The function fetches and caches a remote module file before performing the required trust_remote_code consent check, inverting the security model enforced by other code-loading paths (such as AutoConfig, AutoModel, and AutoTokenizer). As a result, attacker‑controlled Python code from custom_generate/generate.py is copied into the user’s ~/.cache/huggingface/modules directory even if the user declines the trust prompt. Although execution is correctly gated, the file write is not reversible and can persist across sessions. This can lead to persistent, unauthorized files on disk and stale cache collisions where cached attacker code may later be executed during trusted model loads. The issue stems from an unconditional file write in dynamic_module_utils.py prior to any trust verification.
CVSS Information
N/A
Vulnerability Type
N/A
Vulnerability Title
Hugging Face Transformers 权限许可和访问控制问题漏洞
Vulnerability Description
Hugging Face Transformers是Hugging Face公司的一款面向自然语言处理的机器学习模型库。 Hugging Face Transformers 4.49.0版本至5.8.1版本存在安全漏洞,该漏洞源于在信任验证前无条件写入文件,可能导致未经用户同意将远程Python文件写入本地磁盘,并可能导致持久化未授权文件和缓存冲突,使缓存代码可能在后续可信模型加载时被执行。
CVSS Information
N/A
Vulnerability Type
N/A