🔍 CVE-2025-61784

7.6
CVSS Score
HIGH
2025-10-07
2026-10-08 13:10
✅ 완료

🇰🇷 한글 설명

LLaMA-Factory 0.9.4 미만 버전의 chat API에서 인증된 사용자가 임의의 HTTP 요청을 강제할 수 있는 SSRF 취약점이 발견되었습니다. 이 취약점은 내부 네트워크 서비스 노출 및 정찰을 가능하게 하며, 동일한 메커니즘을 통해 서버의 임의 파일을 읽을 수 있는 LFI 취약점으로도 이어질 수 있습니다.

💡 쉬운 설명

해커가 서버에게 가짜 주소를 전달하여 서버가 내부의 비밀 정보를 스스로 찾아내거나 서버 안에 있는 파일을 읽게 만드는 보안 결함입니다. 마치 서버에게 '이 주소에 가서 정보를 가져와'라고 속여서 서버의 권한을 악용하는 것과 같습니다.

🇺🇸 원문 (English)

LLaMA-Factory is a tuning library for large language models. Prior to version 0.9.4, a Server-Side Request Forgery (SSRF) vulnerability in the chat API allows any authenticated user to force the server to make arbitrary HTTP requests to internal and external networks. This can lead to the exposure of sensitive internal services, reconnaissance of the internal network, or interaction with third-party services. The same mechanism also allows for a Local File Inclusion (LFI) vulnerability, enabling users to read arbitrary files from the server's filesystem. The vulnerability exists in the `_process_request` function within `src/llamafactory/api/chat.py.` This function is responsible for processing incoming multimodal content, including images, videos, and audio provided via URLs. The function checks if the provided URL is a base64 data URI or a local file path (`os.path.isfile`). If neither is true, it falls back to treating the URL as a web URI and makes a direct HTTP GET request using `requests.get(url, stream=True).raw` without any validation or sanitization of the URL. Version 0.9.4 fixes the underlying issue.

📍 영향받는 시스템

LLaMA-Factory version < 0.9.4

⚔️ 공격 벡터

인증된 사용자가 chat API를 통해 검증되지 않은 URL을 포함한 멀티모달 콘텐츠를 전송하여 공격

🛡️ 대응 방법

LLaMA-Factory를 최신 버전인 0.9.4 이상으로 업데이트하십시오.

🔧 검증 코드

출력된 Version 값이 0.9.4 미만이면 취약한 상태이며, 0.9.4 이상이면 안전합니다.

Shell / Script
pip show llamafactory | grep Version

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L