ThinkSNS public/minify.php 任意文件包含漏洞

- AV AC AU C I A
发布: 2025-04-13
修订: 2025-04-13

## 漏洞信息: ThinkSNS开源微博系统,是智士的开源社交平台。采用PHP+MySQL技术平台,微博+应用的产品模式,同时拥有iphone、android客户端、wap、3G版界面。 ThinkSNS public/minify.php 存在任意文件包含漏洞,可被利用导致敏感信息泄漏。 ## 漏洞分析: 问题在public/minify.php: ``` allowed_content_types=array('js','css'); $getfiles= explode(',', strip_tags($_GET['f'])); //解析参数 $gettype= (isset($_GET['t']) && $_GET['t']=='css')?'css':'js'; if($gettype=='css'){ $content_type='text/css'; }elseif($gettype=='js'){ $content_type='application/x-javascript'; }else{ die('not allowed content type'); } header ("content-type: ".$content_type."; charset: utf-8");//注意修改到你的编码 header ("cache-control: must-revalidate");// header ("expires: " . gmdate ("D, d M Y H:i:s", time() + 60 * 60 * 24 * 7 ) . " GMT");//过期时间 ob_start("compress"); function compress($buffer) {//去除文件中的注释 $buffer = preg_replace('!/\*[^*]*\*+([^/][^*]*\*+)*/!', '', $buffer); return $buffer; } foreach($getfiles as $file){ $fileType = strtolower( substr($file, strrpos($file, '.') + 1 ) ); if(in_array($fileType,...

0%
暂无可用Exp或PoC
当前有0条受影响产品信息