[BUGFIX] Do not depend on a database connection in CLI authentication
Neither the backend user authentication should try to perform database queries, nor the extbase services. As a side effect this allows to run the cli tool when LocalConfiguration.php or PackageStates.php are missing, which allows to run commands like `dumpautoload` in that case. Note: *Only* in that case, not if a database connection is configured, but not available – for that usecase failsafe booting will be needed, as proposed in https://review.typo3.org/c/58298/ and/or https://review.typo3.org/c/58300/ As a drive-by we also add a null coalescing operator to IconRegistry::registerModuleIcons() which is currently required because ext_tables.php files are loaded in incorrect order if PackageStates.php is missing (reported in another bug: #86408). Although this workaround will not be strictly required when that bug is fixed, that functions should still properly handle that case. Change-Id: I7d339e21160d25b5aee5dd0e2f25491a22ec83e9 Releases: master Resolves: #86416 Related: #86408 Reviewed-on: https://review.typo3.org/58427 Tested-by:TYPO3com <no-reply@typo3.com> Reviewed-by:
Benni Mack <benni@typo3.org> Tested-by:
Benni Mack <benni@typo3.org> Reviewed-by:
Wouter Wolters <typo3@wouterwolters.nl> Reviewed-by:
Stefan Neufeind <typo3.neufeind@speedpartner.de> Reviewed-by:
Christian Kuhn <lolli@schwarzbu.ch> Tested-by:
Christian Kuhn <lolli@schwarzbu.ch>
Showing
- typo3/sysext/core/Classes/Authentication/CommandLineUserAuthentication.php 22 additions, 0 deletions.../Classes/Authentication/CommandLineUserAuthentication.php
- typo3/sysext/core/Classes/Imaging/IconRegistry.php 1 addition, 1 deletiontypo3/sysext/core/Classes/Imaging/IconRegistry.php
- typo3/sysext/extbase/Classes/Command/CoreCommand.php 7 additions, 0 deletionstypo3/sysext/extbase/Classes/Command/CoreCommand.php
Please register or sign in to comment