CTFshow php特性 web127
生活随笔
收集整理的這篇文章主要介紹了
CTFshow php特性 web127
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
目錄
- 源碼
- 思路
- 題解
- 總結
源碼
<?php/* # -*- coding: utf-8 -*- # @Author: h1xa # @Date: 2020-10-10 11:25:09 # @Last Modified by: h1xa # @Last Modified time: 2020-10-10 21:52:49*/error_reporting(0); include("flag.php"); highlight_file(__FILE__); $ctf_show = md5($flag); $url = $_SERVER['QUERY_STRING'];//特殊字符檢測 function waf($url){if(preg_match('/\`|\~|\!|\@|\#|\^|\*|\(|\)|\\$|\_|\-|\+|\{|\;|\:|\[|\]|\}|\'|\"|\<|\,|\>|\.|\\\|\//', $url)){return true;}else{return false;} }if(waf($url)){die("嗯哼?"); }else{extract($_GET); }if($ctf_show==='ilove36d'){echo $flag; }思路
變量覆蓋問題
_被過濾
ctf_show=ilove36d
這種問題bp跑一下就好了
本地
<?phperror_reporting(0); // include("flag.php"); highlight_file(__FILE__); $ctf_show = md5('aaaaa'); $url = $_SERVER['QUERY_STRING']; echo $url."<br>";function waf($url){if(preg_match('/\`|\~|\!|\@|\#|\^|\*|\(|\)|\\$|\_|\-|\+|\{|\;|\:|\[|\]|\}|\'|\"|\<|\,|\>|\.|\\\|\//', $url)){return true;}else{return false;} }if(waf($url)){die("嗯哼?"); }else{extract($_GET); }var_dump($_GET); echo "<br>".$ctf_show;bp
題解
沒思路的話多fuzz一下ctf show=ilove36d
總結
水題
總結
以上是生活随笔為你收集整理的CTFshow php特性 web127的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: CTFshow php特性 web126
- 下一篇: 动态规划算法php,php算法学习之动态