🇰🇷 한글 설명
Werkzeug 3.1.9 미만 버전의 safe_join 함수에서 Windows의 NTFS ADS 마커를 제대로 처리하지 못하는 취약점이 발견되었습니다. 공격자가 NUL:와 같은 특수 장치 경로를 포함한 요청을 보내면, Windows 환경에서 파일 읽기 작업이 무한히 대기 상태에 빠질 수 있습니다.
💡 쉬운 설명
웹 서버가 파일 경로를 확인할 때 특수한 명령어를 걸러내지 못하는 문제입니다. 공격자가 특정 경로를 입력하면 서버가 응답하지 않고 멈춰버릴 수 있습니다.
🇺🇸 원문 (English)
Werkzeug is a comprehensive WSGI web application library. Prior to 3.1.9, the safe_join function used by send_from_directory can allow a NUL: special-device path because safe_join checks the Windows device name without first removing an empty NTFS ADS marker. The trigger is that an application runs on Windows with NTFS and serves a user-specified path ending in a special device name such as NUL:. The attack mechanism is that a requested path ends in a Windows special device name with an empty ADS marker. The impact is that the special device opens successfully and the file read hangs indefinitely. This issue is fixed in version 3.1.9.
📍 영향받는 시스템
Werkzeug 3.1.9 미만 버전 (Windows 및 NTFS 환경)
⚔️ 공격 벡터
사용자가 입력한 경로 끝에 'NUL:'과 같은 Windows 특수 장치 이름과 빈 ADS 마커를 포함하여 요청을 전송
🛡️ 대응 방법
Werkzeug 라이브러리를 3.1.9 버전 이상으로 업데이트
🔧 검증 코드
출력된 버전 번호가 3.1.9보다 낮은지 확인
pip show Werkzeug | grep Version