Project

General

Profile

Bug #24330 » avoid_indexed_by_searchengine.diff

Administrator Admin, 2010-12-13 12:13

View differences:

typo3_src-4.4.4/typo3/sysext/cms/tslib/showpic.php 2010-12-13 12:06:30.000000000 +0100
// ***********************
// If no file-param is given, we must exit
if (!$this->file) {
header('HTTP/1.1 400 Bad Request');
die('Parameter Error: No file given.');
}
......
$GLOBALS['TYPO3_CONF_VARS']['SYS']['encryptionKey'].'|');
if ($md5_value!=$this->md5) {
header('HTTP/1.1 400 Bad Request');
die('Parameter Error: Wrong parameters sent.');
}
......
if (strlen(t3lib_div::_GP('contentHash')) > 0) {
$this->content = t3lib_pageSelect::getHash($this->contentHash);
if (is_null($this->content)) {
header('HTTP/1.1 404 Not Found');
die('Parameter Error: Content not available.');
}
}
......
$test_file=PATH_site.$this->file;
if (!t3lib_div::validPathStr($test_file)) {
header('HTTP/1.1 400 Bad Request');
die('Parameter Error: No valid filepath');
}
if (!@is_file($test_file)) {
header('HTTP/1.1 404 Not Found');
die('The given file was not found');
}
}
(1-1/2)