mirror of
https://github.com/vichan-devel/vichan.git
synced 2024-11-14 10:57:38 +01:00
fix some nonsense
This commit is contained in:
parent
c4b98e94ce
commit
4c827cf105
4
post.php
4
post.php
@ -625,13 +625,15 @@ if (isset($_POST['delete'])) {
|
|||||||
|
|
||||||
if ($post['has_file']) {
|
if ($post['has_file']) {
|
||||||
foreach ($post['files'] as $key => &$file) {
|
foreach ($post['files'] as $key => &$file) {
|
||||||
if ($file['is_an_image'] && $config['ie_mime_type_detection'] !== false) {
|
if ($file['is_an_image']) {
|
||||||
|
if ($config['ie_mime_type_detection'] !== false) {
|
||||||
// Check IE MIME type detection XSS exploit
|
// Check IE MIME type detection XSS exploit
|
||||||
$buffer = file_get_contents($upload, null, null, null, 255);
|
$buffer = file_get_contents($upload, null, null, null, 255);
|
||||||
if (preg_match($config['ie_mime_type_detection'], $buffer)) {
|
if (preg_match($config['ie_mime_type_detection'], $buffer)) {
|
||||||
undoImage($post);
|
undoImage($post);
|
||||||
error($config['error']['mime_exploit']);
|
error($config['error']['mime_exploit']);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
require_once 'inc/image.php';
|
require_once 'inc/image.php';
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user