Getting 100's of Backtrace: USER NOTICE: Image not found Errors

Hi,

I was checking my logs this morning and I'm seeing literally 1000's of these identical errors in my log.

The gallery etc is all displaying fine and working great

http://spoilertv.co.uk/images

I was curious as to what might be causing this?

Here is a sample of the errors (they are all the same)

{Sun, 04 Aug 2013 22:32:51 GMT} Zenphoto v1.4.3.1[10590]
Backtrace: USER NOTICE: Image not found; file does not exist. in /home/spoilert/public_html/images/zp-core/functions-image.php on line 33
trigger_error called
from imageError (functions-image.php [33])
from i.php [185]

This is the code from the fuctions-image.php file

Line 33 is the trigger_error($errormessage, E_USER_NOTICE); line

function imageError($status_text, $errormessage, $errorimg='err-imagegeneral.png') {
global $newfilename, $album, $image;
$debug = isset($_GET['debug']);
if ($debug) {
echo(''.sprintf(gettext('Zenphoto Image Processing Error: %s'), $errormessage).''
. '

'.sprintf(gettext('Request URI: [ `%s` ]'), sanitize($_SERVER['REQUEST_URI'], 3))
. 'PHP_SELF: [ `' . sanitize($_SERVER['PHP_SELF'], 3) . '` ]'
. (empty($newfilename) ? '' : ''.sprintf(gettext('Cache: [`%s`]'), '/'.CACHEFOLDER.'/' . sanitize($newfilename, 3)).' ')
. (empty($image) || empty($album) ? '' : ' '.sprintf(gettext('Image: [`%s`]'),sanitize($album.'/'.$image, 3)).' '));
} else {
trigger_error($errormessage, E_USER_NOTICE);
header("HTTP/1.0 $status_text");
header("Status: $status_text");
header('Location: ' . FULLWEBPATH . '/' . ZENFOLDER . '/images/' . $errorimg);
}
exitZP();
}

Here is the code from i.php. Line 185 is the imageError('404 Not Found', gettext("Image not found; file does not exist."), 'err-imagenotfound.png'); link

if (!file_exists($imgfile)) {
header("HTTP/1.0 404 Not Found");
header("Status: 404 Not Found");
imageError('404 Not Found', gettext("Image not found; file does not exist."), 'err-imagenotfound.png');
}

Comments

  • acrylian Administrator, Developer
    Please look at your server access log. If someone for example requests an image page url (yourdomain.com/album/image.jpg.php for example) that does not exists the image of course does also not and would throw an error. Sometimes spammers try these things.
  • Ah, thanks Acrylian. That would certainly explain it.

    I suspected something like that. Glad to know.

    Thanks for the reply.
  • If you were running the current version of Zenphoto you could enable the image processor security option and these access attempts would be blocked.
Sign In or Register to comment.