🇰🇷 한글 설명
NiceGUI 3.10.0 이전 버전에서 경로 검증 우회 취약점 발생. PurePosixPath는 슬래시(/)만 인식하므로, Windows에서 백슬래시(\)를 파일명에 포함하면 경로 검증을 우회하여 임의 위치에 파일을 쓸 수 있다. 특히 file.name을 사용하는 예제 코드가 영향을 받음.
💡 쉬운 설명
NiceGUI에서 파일을 업로드할 때, 공격자가 특수한 경로 문자를 사용하면 의도하지 않은 폴더에 파일을 저장할 수 있습니다(Windows만 해당). 버전 3.10.0으로 업그레이드하면 이 문제가 해결됩니다.
🇺🇸 원문 (English)
NiceGUI is a Python-based UI framework. Prior to 3.10.0, Since PurePosixPath only recognizes forward slashes (/) as path separators, an attacker can bypass this sanitization on Windows by using backslashes (\) in the upload filename. Applications that construct file paths using file.name (a pattern demonstrated in NiceGUI's bundled examples) are vulnerable to arbitrary file write on Windows. This vulnerability is fixed in 3.10.0.
📍 영향받는 시스템
NiceGUI < 3.10.0 (Windows 플랫폼)
⚔️ 공격 벡터
업로드 파일명에 백슬래시(\\)를 포함하여 경로 검증 우회 후 임의 위치에 파일 쓰기
🛡️ 대응 방법
NiceGUI를 3.10.0 이상으로 업그레이드
🔧 검증 코드
출력된 Version 번호가 3.10.0 이상이면 패치됨. 이하이면 취약.
pip show nicegui | grep Version