almost 9 years ago
在 response header 裡,有一些提示。
Connection:Keep-Alive
Content-Length:173
Content-Type:text/html
Date:Mon, 29 Sep 2014 13:58:15 GMT
HintLine1:$upload_dir = "./tmp/";
HintLine2:$rand = mt_rand();
HintLine3:$filename = md5($_FILES["file"]["name"]).sha1($rand);
Keep-Alive:timeout=5, max=100
Server:Apache/2.4.9 (Win32) OpenSSL/0.9.8y PHP/5.3.28
X-Powered-By:PHP/5.3.28
所以上傳的文件會在 http://202.120.7.66:8888/tmp/
下,然後注意到 Server:Apache/2.4.9 (Win32)
Windows 下可以使用 8.3 格式的短檔名拿到檔案,如果上傳檔名是 a
則
md5('a') = 0cc175b9c0f1b6a831c399e269772661
,只要用 tmp/0cc175~1
就可以拿到上傳的檔案,
後半段的 sha1 不重要。
只要拿到檔案就會直接顯示 Flag 了: ISG{u_sUcCEssFuLlY_F1nd_YOuR_sHe11}