🇰🇷 한글 설명
langgenius dify 1.13.3 이하 버전의 web/app/components/base/image-uploader/image-preview.tsx 파일 내 ImagePreview 컴포넌트의 openInNewTab 함수에서, filename 인자 조작을 통해 크로스 사이트 스크립팅(XSS)이 발생할 수 있습니다. 공격은 원격으로 시작될 수 있으며, 공개된 익스플로잇이 존재합니다. 벤더에 사전 통보했으나 응답이 없었습니다.
💡 쉬운 설명
이미지 미리보기 기능에서 파일 이름에 악성 스크립트를 넣을 수 있는 취약점입니다. 공격자가 만든 링크를 사용자가 열면 악성 코드가 실행되어 계정 정보가 탈취될 수 있습니다.
🇺🇸 원문 (English)
A vulnerability has been found in langgenius dify up to 1.13.3. Impacted is the function openInNewTab of the file web/app/components/base/image-uploader/image-preview.tsx of the component ImagePreview. The manipulation of the argument filename leads to cross site scripting. The attack may be initiated remotely. The exploit has been disclosed to the public and may be used. The vendor was contacted early about this disclosure but did not respond in any way.
📍 영향받는 시스템
langgenius dify 1.13.3 이하 버전
⚔️ 공격 벡터
공격자가 조작된 파일명을 포함한 링크나 파일을 제공하고, 사용자가 이미지 미리보기를 열면 스크립트가 실행됨
🛡️ 대응 방법
dify를 1.13.3보다 높은 패치 버전으로 업데이트하고, 공식 릴리스 확인 후 적용
🔧 검증 코드
명령어 결과에 openInNewTab 함수가 출력되고 filename 값이 이스케이프 없이 사용되면 취약한 상태이며, 결과가 없으면 파일이 없거나 패치된 버전일 가능성이 있으므로 dify 버전을 함께 확인해야 합니다.
grep -rn 'openInNewTab' $(find / -path '*/web/app/components/base/image-uploader/image-preview.tsx' 2>/dev/null) 2>/dev/null | head -5