这样看太麻烦了,他给了提示,查看源代码
I put something in F12 for you
include 'flag.php';
$flag='MRCTF{xxxxxxxxxxxxxxxxxxxxxxxxx}';
if(isset($_GET['gg'])&&isset($_GET['id'])) {
$id=$_GET['id'];
$gg=$_GET['gg'];
if (md5($id) === md5($gg) && $id !== $gg) {
echo 'You got the first step';
if(isset($_POST['passwd'])) {
$passwd=$_POST['passwd'];
if (!is_numeric($passwd))
{
if($passwd==1234567)
{
echo 'Good Job!';
highlight_file('flag.php');
die('By Retr_0');
}
else
{
echo "can you think twice??";
}
}
else{
echo 'You can not get it !';
}
}
else{
die('only one way to get the flag');
}
}
else {
echo "You are not a real hacker!";
}
}
else{
die('Please input first');
}
}Please input first
代码提示这儿有两步
第一步
使用get传参的方式,进行md5强比较,如果id=gg,呢么第一步就通过了,这儿有两种方法,第一种就是使用两个值相同的md5值进行绕过,第二种是数组绕过,之前使用过了第一种方法,这儿我们使用第二种方法,我们构造playload ?id[ ]=1&gg=[ ]2
给了提示,我们已经通过第一步了
第二步
我们要进行post传参,这儿考弱比较,passwd需要等于1234567,但是passwd又不能等于数字类型,这儿我们进行绕过,在后面随便加一个字母就行了
使用hackbar进行post传参 passwd=1234567a
得到我们需要的flag了