[TASK] Remove BE/TSconfigConditions setting 38/23838/2
authorChristian Kuhn <lolli@schwarzbu.ch>
Sat, 14 Sep 2013 23:58:07 +0000 (01:58 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Mon, 16 Sep 2013 04:50:12 +0000 (06:50 +0200)
Did you know there is an option to disable condition parsing in
TS config? It is removed with the patch.

Change-Id: If6ce720a4416af80b7deb293160e8b712c04ff0d
Resolves: #52013
Releases: 6.2
Reviewed-on: https://review.typo3.org/23838
Reviewed-by: Anja Leichsenring
Tested-by: Anja Leichsenring
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
typo3/sysext/backend/Classes/Utility/BackendUtility.php
typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php
typo3/sysext/core/Configuration/DefaultConfiguration.php
typo3/sysext/install/Classes/Controller/StepController.php

index 6ff8e45..fa92b5e 100644 (file)
@@ -1143,27 +1143,13 @@ class BackendUtility {
                if ($returnPartArray) {
                        return $TSdataArray;
                }
-               // Parsing the page TS-Config (or getting from cache)
+               // Parsing the page TS-Config
                $pageTS = implode(LF . '[GLOBAL]' . LF, $TSdataArray);
-               if ($GLOBALS['TYPO3_CONF_VARS']['BE']['TSconfigConditions']) {
-                       /* @var $parseObj \TYPO3\CMS\Backend\Configuration\TsConfigParser */
-                       $parseObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Configuration\\TsConfigParser');
-                       $res = $parseObj->parseTSconfig($pageTS, 'PAGES', $id, $rootLine);
-                       if ($res) {
-                               $TSconfig = $res['TSconfig'];
-                       }
-               } else {
-                       $hash = md5('pageTS:' . $pageTS);
-                       $cachedContent = self::getHash($hash);
-                       $TSconfig = array();
-                       if (isset($cachedContent)) {
-                               $TSconfig = unserialize($cachedContent);
-                       } else {
-                               $parseObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\TypoScript\\Parser\\TypoScriptParser');
-                               $parseObj->parse($pageTS);
-                               $TSconfig = $parseObj->setup;
-                               self::storeHash($hash, serialize($TSconfig), 'PAGES_TSconfig');
-                       }
+               /* @var $parseObj \TYPO3\CMS\Backend\Configuration\TsConfigParser */
+               $parseObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Configuration\\TsConfigParser');
+               $res = $parseObj->parseTSconfig($pageTS, 'PAGES', $id, $rootLine);
+               if ($res) {
+                       $TSconfig = $res['TSconfig'];
                }
                // Get User TSconfig overlay
                $userTSconfig = $GLOBALS['BE_USER']->userTS['page.'];
@@ -4076,4 +4062,4 @@ class BackendUtility {
        }
 
 }
-?>
+?>
\ No newline at end of file
index bd46789..7654da5 100644 (file)
@@ -1272,7 +1272,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU
                        $this->TSdataArray = \TYPO3\CMS\Core\TypoScript\Parser\TypoScriptParser::checkIncludeLines_array($this->TSdataArray);
                        // Imploding with "[global]" will make sure that non-ended confinements with braces are ignored.
                        $this->userTS_text = implode(LF . '[GLOBAL]' . LF, $this->TSdataArray);
-                       if ($GLOBALS['TYPO3_CONF_VARS']['BE']['TSconfigConditions'] && !$this->userTS_dontGetCached) {
+                       if (!$this->userTS_dontGetCached) {
                                // Perform TS-Config parsing with condition matching
                                $parseObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Configuration\\TsConfigParser');
                                $res = $parseObj->parseTSconfig($this->userTS_text, 'userTS');
@@ -2392,4 +2392,4 @@ This is a dump of the failures:
 }
 
 
-?>
+?>
\ No newline at end of file
index 1c6aa65..60248ce 100644 (file)
@@ -569,7 +569,6 @@ return array(
                'notificationPrefix' => '[TYPO3 Note]',                         // String: Used to prefix the subject of mails sent in the taskcenter
                'accessListRenderMode' => 'checkbox',                           // Can be "singlebox", "checkbox" or blank. Refers to the "renderMode" for the selector boxes in be-groups configuration.
                'explicitADmode' => 'explicitDeny',                                     // Sets the general allow/deny mode for selector box values. Value can be either "explicitAllow" or "explicitDeny", nothing else!
-               'TSconfigConditions' => TRUE,                                           // Boolean: When set it is possible to have TypoScript like conditions in BE Page/User/Group TS-Config
                'niceFlexFormXMLtags' => TRUE,                                          // If set, the flexform XML will be stored with meaningful tags which can be validated with DTD schema. If you rely on custom reading of the XML from pre-4.0 versions you should set this to FALSE if you don't like to change your reader code (internally it is insignificant since \TYPO3\CMS\Core\Utility\GeneralUtility::xml2array() doesn't care for the tags if the index-attribute value is set)
                'flexFormXMLincludeDiffBase' => TRUE,                           // If set, an additional tag with index "vXX.vDEFbase" is created for translations in flexforms holding the value of the default language when translation was changed. Used to show diff of value. This setting will change whether the system thinks flexform XML looks clean. For example when FALSE XX.vDEFbase fields will be removed in cleaning while accepted if TRUE (of course)
                'compactFlexFormXML' => 0,                                                      // If set, the flexform XML will not contain indentation spaces making XML more compact
index 7b3cc7c..ba15de5 100644 (file)
@@ -52,6 +52,8 @@ class StepController extends AbstractController {
                'BE/loginLabels',
                // #44506
                'BE/loginNews',
+               // #52013
+               'BE/TSconfigConditions',
                // #30613
                'BE/useOnContextMenuHandler',
                // #48179
@@ -456,4 +458,4 @@ class StepController extends AbstractController {
                }
        }
 }
-?>
\ No newline at end of file
+?>