[BUGFIX] Remove HTML in RuntimeException from sysext 'install' 07/17007/2
authorPhilipp Gampe <philipp.gampe@typo3.org>
Sun, 23 Sep 2012 10:34:53 +0000 (12:34 +0200)
committerDmitry Dulepov <dmitry@typo3.org>
Mon, 10 Dec 2012 11:28:08 +0000 (12:28 +0100)
It is not possible to use HTML code inside runtime exceptions. This code
will be htmlspecialchared and printed to the user.

Replace <em></em> with double quotes and remove the <br /> tags
completely, because exception messages are single line only.

Change-Id: I28376736d1a9c8ce4acd57db5cfe7ac332b3a2f1
Fixes: #38472
Releases: 6.1, 6.0, 4.7, 4.6, 4.5
Reviewed-on: https://review.typo3.org/17007
Reviewed-by: Oliver Klee
Reviewed-by: Dmitry Dulepov
Tested-by: Dmitry Dulepov
typo3/sysext/install/mod/class.tx_install.php

index a9eeb9d..0bef25d 100644 (file)
@@ -306,9 +306,10 @@ class tx_install extends t3lib_install {
                                // Check for mandatory PHP modules
                        $missingPhpModules = $this->getMissingPhpModules();
                        if (count($missingPhpModules) > 0) {
-                               throw new RuntimeException('TYPO3 Installation Error: The following PHP module(s) is/are missing: <em>' .
-                                               implode(', ', $missingPhpModules) .
-                                               '</em><br /><br />You need to install and enable these modules first to be able to install TYPO3.'
+                               throw new RuntimeException('TYPO3 Installation Error: The following PHP module(s) is/are missing: "' .
+                                               implode('", "', $missingPhpModules) .
+                                               '". You need to install and enable these modules first to be able to install TYPO3.',
+                                       1294587482
                                );
                        }
                }