🔍 CVE-2024-40624

9.8
CVSS Score
CRITICAL
2024-07-15
2026-04-15 00:35
✅ 완료

🇰🇷 한글 설명

TorrentPier의 functions.php에서 사용자 쿠키를 안전하지 않은 PHP 직렬화 형식으로 역직렬화하는 취약점입니다. phpggc 도구를 활용한 Guzzle/FW1 체인을 통해 임의의 파일에 PHP 코드를 작성하고 시스템 명령을 실행할 수 있습니다.

💡 쉬운 설명

웹사이트의 쿠키 설정을 통해 악의적인 코드가 서버에서 실행되는 문제입니다. 공격자가 특수하게 만든 쿠키를 보내면 서버의 모든 권한으로 원하는 명령을 실행할 수 있습니다.

🇺🇸 원문 (English)

TorrentPier is an open source BitTorrent Public/Private tracker engine, written in php. In `torrentpier/library/includes/functions.php`, `get_tracks()` uses the unsafe native PHP serialization format to deserialize user-controlled cookies. One can use phpggc and the chain Guzzle/FW1 to write PHP code to an arbitrary file, and execute commands on the system. For instance, the cookie bb_t will be deserialized when browsing to viewforum.php. This issue has been addressed in commit `ed37e6e52` which is expected to be included in release version 2.4.4. Users are advised to upgrade as soon as the new release is available. There are no known workarounds for this vulnerability.

📍 영향받는 시스템

TorrentPier 2.4.4 이전 모든 버전

⚔️ 공격 벡터

viewforum.php 접근 시 조작된 bb_t 쿠키 값을 전송하여 역직렬화 기반 RCE 체인 실행

🛡️ 대응 방법

TorrentPier를 2.4.4 이상으로 즉시 업그레이드 (커밋 ed37e6e52 포함)

🔧 검증 코드

설치 경로에서 VERSION 파일의 버전이 2.4.4 미만이면 취약, 또는 functions.php 파일 존재 확인으로 설치 여부 판단

Shell / Script
test -f /var/www/torrentpier/VERSION && cat /var/www/torrentpier/VERSION || find /var/www -name functions.php -path '*torrentpier*' 2>/dev/null | head -1

📊 CVSS Vector String

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

💻 영향받는 소프트웨어

PHP