# 22.2.4

> 今天被车撞了哈哈哈哈哈哈哈哈

## 0x01 ctfhub web 网站源码

1. 不得不说，ctfhub的启动速度真慢，而且还限时。
2. 诶，好像做完了再写得，就是直接看源码就好了。

## 0x02 ctfhub web 目录遍历

1. python代码

   ```python
   list1=['tar','tar.gz','zip','rar']
   list2=['web','website','backup','back','www','wwwroot','temp']
   from http.client import ImproperConnectionState
   from itertools import product
   from wsgiref import headers
   loop_val = [list2,list1]
   
   import requests
   url="http://challenge-fa64d15e79dc640d.sandbox.ctfhub.com:10800/"
   headers={}
   
   
   for i in list1:
     for j in list2:
       url="http://challenge-fa64d15e79dc640d.sandbox.ctfhub.com:10800/"
   
       tmpurl=url+j+"."+i
       print("-----")
       print(tmpurl)
       resp = requests.get(tmpurl,headers=headers)
       print(resp)
   
   
   ```

   输出:

   ```shell
   http://challenge-fa64d15e79dc640d.sandbox.ctfhub.com:10800/www.zip
   <Response [200]>
   ```

2. 下载之后为zip

   ```sh
   ├── 50x.html
   ├── flag_963527584.txt
   └── index.html
   ```

3. 访问`http://challenge-fa64d15e79dc640d.sandbox.ctfhub.com:10800/flag_963527584.txt`

4. `ctfhub{734a166d266f051f9cb234ef}`



### 吼住

1. 可以用这个东西

   ```sh
   python3 dirsearch.py -u https://balbalab -e *
   ```

   

## 0x03 ctfhub web bak文件

1. `http://challenge-e31abed617b09446.sandbox.ctfhub.com:10800/index.php.bak`

3. | FLAG | ctfhub{d588e073d217316d7b3a3c0a} |
   | ---- | -------------------------------- |

## 0x04 ctfhub web vim缓存

1. 查了查WP还是，实在不知道vim的缓存叫啥
2. `http://challenge-3b111743009ec124.sandbox.ctfhub.com:10800/.index.php.swp`
3. 然后`vim -r file`
4. | FLAG | ctfhub{c49261bb85e4089818bc894d} |
   | ---- | -------------------------------- |

### 吼鸡

1. vim 可以用v进入可视模式，然后安y进行复制。
2. 其实WSL挺好用的！