一、漏洞点发现进入靶场,发现存在一个表单,可以向page页面用GET请求方式发送一个名为url的参数,当你输入一个URL时会给你返回一个后缀为.jpg但内容为你的目标URL文件。<!doctype html> <html> <head> <title>test</title> </head> <body> <form action="/page" method="get"> <input type="text" name="url"/> </form> </body> </html>经过测试,url参数存在任意文件读取漏洞:访问/page?url=/etc/passwd:HTTP/1.1 200 OK Server: openresty Date: Wed, 12 Jun 2024 06:32:57 GMT Con
一、信息收集扫描目录,发现index.php.swp文件。ob_start(); function get_hash(){ $chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789!@#$%^&*()+-'; $random = $chars[mt_rand(0,73)].$chars[mt_rand(0,73)].$chars[mt_rand(0,73)].$chars[mt_rand(0,73)].$chars[mt_rand(0,73)];//Random 5 times $content = uniqid().$random; return sha1($content); } header("Content-Type: text/html;charset=utf-8"); //*** if(isset($_POST['username']) and $_POST['username'] != '' ) { $admin =
原理Tomcat AJP协议由于存在实现缺陷导致相关参数可控,攻击者利用该漏洞可通过构造特定参数,读取服务器webapps目录下的任意文件,但不能跨到上级目录。影响范围Apache Tomcat 6 ALLApache Tomcat 7 < 7.0.100Apache Tomcat 8 < 8.5.51Apache Tomcat 9 < 9.0.31危害在网站存在文件上传功能时可通过该漏洞进行文件包含执行代码。POC & EXPfofaport="8009"&& country="CN"脚本链接https://github.com/00theway/Ghostcat-CNVD-2020-10487/
Equinox
一个乐于分享的网安人