🇰🇷 한글 설명
Python Liquid 2.2.0 미만 버전의 FileSystemLoader 및 CachingFileSystemLoader에서 절대 경로를 사용할 경우 지정된 검색 경로 외부의 파일을 읽을 수 있는 취약점이 존재합니다. 공격자는 {% include %} 또는 {% render %} 태그를 사용하여 애플리케이션 프로세스가 읽을 수 있는 임의의 파일을 로드하고 렌더링할 수 있습니다.
💡 쉬운 설명
템플릿 엔진의 보안 허점을 이용해 허용되지 않은 시스템 파일을 몰래 읽어올 수 있는 문제입니다. 공격자가 특수하게 제작된 코드를 입력하면 서버 내부의 중요한 파일이 노출될 수 있습니다.
🇺🇸 원문 (English)
Python Liquid is a Python engine for the Liquid template language. Prior to 2.2.0, the built-in FileSystemLoader and CachingFileSystemLoader do not guard against reading files outside their search paths when given an absolute path to resolve. This allows malicious template authors to load and render arbitrary files via the {% include %} and {% render %} tags. Targeted files would need to contain valid Liquid markup and be readable by the application process. This vulnerability is fixed in 2.2.0.
📍 영향받는 시스템
Python Liquid versions prior to 2.2.0
⚔️ 공격 벡터
템플릿 내 {% include %} 또는 {% render %} 태그에 절대 경로를 삽입하여 외부 파일 접근
🛡️ 대응 방법
Python Liquid 라이브러리를 2.2.0 버전 이상으로 업데이트
🔧 검증 코드
출력된 Version 값이 2.2.0 미만이면 취약한 상태이며, 2.2.0 이상이면 안전합니다.
pip show liquid | grep -E 'Version'