[BUGFIX] Security status for saltedpasswords broken 89/33689/2
authorWouter Wolters <typo3@wouterwolters.nl>
Sat, 1 Nov 2014 12:54:11 +0000 (13:54 +0100)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Sat, 1 Nov 2014 13:17:29 +0000 (14:17 +0100)
Due to the new flashmessage styling the checks done for
saltedpasswords don't work anymore. Change the checks to the
new class names.

Resolves: #62598
Releases: master
Change-Id: Iea269f1d138e58cd551fa5575f3b03455a48d930
Reviewed-on: http://review.typo3.org/33689
Reviewed-by: Frank Nägler <typo3@naegler.net>
Tested-by: Frank Nägler <typo3@naegler.net>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
typo3/sysext/reports/Classes/Report/Status/SecurityStatus.php

index 3e13a15..623f81e 100644 (file)
@@ -206,23 +206,23 @@ class SecurityStatus implements \TYPO3\CMS\Reports\StatusProviderInterface {
                $message = '<p>' . $GLOBALS['LANG']->getLL('status_saltedPasswords_infoText') . '</p>';
                $messageDetail = '';
                $flashMessage = $configCheck->checkConfigurationBackend(array(), new \TYPO3\CMS\Core\TypoScript\ConfigurationForm());
-               if (strpos($flashMessage, 'message-error') !== FALSE) {
+               if (strpos($flashMessage, 'alert-danger') !== FALSE) {
                        $value = $GLOBALS['LANG']->getLL('status_insecure');
                        $severity = \TYPO3\CMS\Reports\Status::ERROR;
                        $messageDetail .= $flashMessage;
                }
-               if (strpos($flashMessage, 'message-warning') !== FALSE) {
+               if (strpos($flashMessage, 'alert-warning') !== FALSE) {
                        $severity = \TYPO3\CMS\Reports\Status::WARNING;
                        $messageDetail .= $flashMessage;
                }
-               if (strpos($flashMessage, 'message-information') !== FALSE) {
+               if (strpos($flashMessage, 'alert-info') !== FALSE) {
                        $messageDetail .= $flashMessage;
                }
                $unsecureUserCount = \TYPO3\CMS\Saltedpasswords\Utility\SaltedPasswordsUtility::getNumberOfBackendUsersWithInsecurePassword();
                if ($unsecureUserCount > 0) {
                        $value = $GLOBALS['LANG']->getLL('status_insecure');
                        $severity = \TYPO3\CMS\Reports\Status::ERROR;
-                       $messageDetail .= '<div class="typo3-message message-warning">' . $GLOBALS['LANG']->getLL('status_saltedPasswords_notAllPasswordsHashed') . '</div>';
+                       $messageDetail .= '<div class="alert alert-warning">' . $GLOBALS['LANG']->getLL('status_saltedPasswords_notAllPasswordsHashed') . '</div>';
                }
                $message .= $messageDetail;
                if (empty($messageDetail)) {