* Security enhancement: Prevent image access through thumbs.php. For details...
[Packages/TYPO3.CMS.git] / t3lib / class.t3lib_userauth.php
index 2a3755e..831c1bc 100755 (executable)
@@ -403,6 +403,11 @@ class t3lib_userAuth {
                                        // delete old user session if any
                                $this->logoff();
                        }
+
+                               // Refuse login for _CLI users (used by commandline scripts)
+                       if ((strtoupper(substr($loginData['uname'],0,5))=='_CLI_') && (!defined('TYPO3_cliMode') || !TYPO3_cliMode))    {       // although TYPO3_cliMode should never be set when using active login...
+                               die('Error: You have tried to login using a CLI user. Access prohibited!');
+                       }
                }