Commit d73a05d2 authored by Wouter Wolters's avatar Wouter Wolters Committed by Helmut Hummel
Browse files

[TASK] Remove version number from generator tag

This change will not increase the security of TYPO3 CMS.
This information can be misused by an attacker for a more targeted attack.

Resolves: #64429
Releases: master,6.2
Change-Id: I9151ed99e454e878b10ec1894cbec2ad83165e57
Reviewed-on: http://review.typo3.org/37945


Reviewed-by: default avatarHelmut Hummel <helmut.hummel@typo3.org>
Tested-by: default avatarHelmut Hummel <helmut.hummel@typo3.org>
Reviewed-by: Andreas Fernandez's avatarAndreas Fernandez <typo3@scripting-base.de>
Tested-by: Andreas Fernandez's avatarAndreas Fernandez <typo3@scripting-base.de>
parent 60856031
......@@ -1239,7 +1239,7 @@ function jumpToUrl(URL) {
* @return string <meta> tag with name "generator
*/
public function generator() {
$str = 'TYPO3 ' . TYPO3_branch . ', ' . TYPO3_URL_GENERAL . ', &#169; Kasper Sk&#229;rh&#248;j ' . TYPO3_copyright_year . ', extensions are copyright of their respective owners.';
$str = 'TYPO3 CMS, ' . TYPO3_URL_GENERAL . ', &#169; Kasper Sk&#229;rh&#248;j ' . TYPO3_copyright_year . ', extensions are copyright of their respective owners.';
return '<meta name="generator" content="' . $str . '" />';
}
......
......@@ -1185,7 +1185,7 @@ class PageGenerator {
$endingSlash = $xhtml ? ' /' : '';
$metaTags = array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '"' . $endingSlash . '>'
'<meta name="generator" content="TYPO3 CMS"' . $endingSlash . '>'
);
/** @var TypoScriptService $typoScriptService */
......
......@@ -53,7 +53,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
FALSE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '">',
'<meta name="generator" content="TYPO3 CMS">',
'<meta name="author" content="Markus Klein">',
)
),
......@@ -63,7 +63,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
TRUE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '" />',
'<meta name="generator" content="TYPO3 CMS" />',
'<meta name="author" content="Markus Klein" />',
)
),
......@@ -74,7 +74,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
FALSE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '">',
'<meta name="generator" content="TYPO3 CMS">',
'<meta name="author" content="Markus Klein">',
)
),
......@@ -85,7 +85,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
FALSE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '">',
'<meta name="generator" content="TYPO3 CMS">',
'<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">'
)
),
......@@ -96,7 +96,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
TRUE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '" />',
'<meta name="generator" content="TYPO3 CMS" />',
'<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />'
)
),
......@@ -106,7 +106,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
FALSE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '">',
'<meta name="generator" content="TYPO3 CMS">',
'<meta http-equiv="refresh" content="10">',
)
),
......@@ -116,7 +116,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
FALSE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '">',
'<meta name="generator" content="TYPO3 CMS">',
'<meta name="DC.author" content="Markus Klein">',
)
),
......@@ -126,7 +126,7 @@ class PageGeneratorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
),
FALSE,
array(
'<meta name="generator" content="TYPO3 CMS ' . TYPO3_branch . '">',
'<meta name="generator" content="TYPO3 CMS">',
'<meta name="OG:title" content="Magic Tests">',
)
),
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment