106 trigger_error(
'FrontendBackendUserAuthentication->initializeAdminPanel() will be removed in TYPO3 v10.0 - initialization is done via middleware.', E_USER_DEPRECATED);
116 trigger_error(
'FrontendBackendUserAuthentication->initializeFrontendEdit() will be removed in TYPO3 v10.0 - initialization is done via middleware.', E_USER_DEPRECATED);
127 trigger_error(
'FrontendBackendUserAuthentication->isFrontendEditingActive() will be removed in TYPO3 v10.0 - use underlying TSFE directly.', E_USER_DEPRECATED);
128 return $this->extAdmEnabled && (
129 $this->adminPanel->isAdminModuleEnabled(
'edit') ||
130 (int)
$GLOBALS[
'TSFE']->displayEditIcons === 1 ||
131 (
int)
$GLOBALS[
'TSFE']->displayFieldEditIcons === 1
143 trigger_error(
'FrontendBackendUserAuthentication->displayAdminPanel() will be removed in TYPO3 v10.0 - use MainController of adminpanel extension.', E_USER_DEPRECATED);
144 return $this->adminPanel->display();
155 trigger_error(
'FrontendBackendUserAuthentication->isAdminPanelVisible() will be removed in TYPO3 v10.0 - use new adminpanel API instead.', E_USER_DEPRECATED);
156 return $this->extAdmEnabled && !$this->extAdminConfig[
'hide'] &&
$GLOBALS[
'TSFE']->config[
'config'][
'admPanel'];
173 trigger_error(
'FrontendBackendUserAuthentication->checkBackendAccessSettingsFromInitPhp() will be removed in TYPO3 v10.0. Use a PSR-15 middleware and backendCheckLogin() instead.', E_USER_DEPRECATED);
175 if (
$GLOBALS[
'TYPO3_CONF_VARS'][
'BE'][
'adminOnly'] < 0) {
179 if (trim(
$GLOBALS[
'TYPO3_CONF_VARS'][
'BE'][
'IPmaskList'])) {
180 if (!GeneralUtility::cmpIP(GeneralUtility::getIndpEnv(
'REMOTE_ADDR'),
$GLOBALS[
'TYPO3_CONF_VARS'][
'BE'][
'IPmaskList'])) {
189 if ((
bool)
$GLOBALS[
'TYPO3_CONF_VARS'][
'BE'][
'lockSSL'] && !GeneralUtility::getIndpEnv(
'TYPO3_SSL')) {
205 if (empty($this->user[
'uid'])) {
209 if (
$GLOBALS[
'TYPO3_CONF_VARS'][
'BE'][
'adminOnly'] < 0) {
234 trigger_error(
'FrontendBackendUserAuthentication->extPageReadAccess() will be removed in TYPO3 v10.0.', E_USER_DEPRECATED);
256 trigger_error(
'FrontendBackendUserAuthentication->extGetTreeList() will be removed in TYPO3 v10.0.', E_USER_DEPRECATED);
258 $queryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)
259 ->getQueryBuilderForTable(
'pages');
261 $queryBuilder->getRestrictions()
263 ->add(GeneralUtility::makeInstance(DeletedRestriction::class));
265 $depth = (int)$depth;
266 $begin = (int)$begin;
269 if (
$id && $depth > 0) {
270 $result = $queryBuilder
271 ->select(
'uid',
'title')
274 $queryBuilder->expr()->eq(
'pid', $queryBuilder->createNamedParameter(
$id, \PDO::PARAM_INT)),
275 $queryBuilder->expr()->eq(
'sys_language_uid', 0),
279 while ($row = $result->fetch()) {
281 $theList .= $row[
'uid'] .
',';
284 $theList .= $this->
extGetTreeList($row[
'uid'], $depth - 1, $begin - 1, $perms_clause);
307 $languageAspect = GeneralUtility::makeInstance(Context::class)->getAspect(
'language');
308 if ($table ===
'pages') {
309 $languageId = $languageAspect->getId();
310 } elseif ($table ===
'tt_content') {
311 $languageId = $languageAspect->getContentId();
312 } elseif (
$GLOBALS[
'TCA'][$table][
'ctrl'][
'languageField']) {
313 $languageId = $currentRecord[
$GLOBALS[
'TCA'][$table][
'ctrl'][
'languageField']];
329 public function allowedToEdit(
string $table, array $dataArray, array $conf,
bool $checkEditAccessInternals): bool
333 if ($checkEditAccessInternals) {
336 $editAccessInternals =
true;
338 if ($editAccessInternals) {
339 $restrictEditingToRecordsOfCurrentPid = !empty($conf[
'onlyCurrentPid'] ??
false);
342 } elseif ($table ===
'pages') {
353 if (!$restrictEditingToRecordsOfCurrentPid || $dataArray[
'pid'] ==
$GLOBALS[
'TSFE']->
id) {
355 if ($table ===
'pages') {
358 if (!empty($allow)) {
363 $types = GeneralUtility::trimExplode(
',', strtolower($conf[
'allow']),
true);
364 $allow = array_flip($types);
382 $types = GeneralUtility::trimExplode(
',', strtolower($conf[
'allow']),
true);
383 $allow = array_flip($types);
384 if (!$conf[
'onlyCurrentPid'] || $pid ==
$GLOBALS[
'TSFE']->
id) {
386 $types = GeneralUtility::trimExplode(
',', strtolower($conf[
'allow']),
true);
387 $allow = array_flip($types);
389 if ($table ===
'pages') {
391 if (count(
$GLOBALS[
'TSFE']->config[
'rootLine']) === 1) {
392 unset($allow[
'move']);
393 unset($allow[
'hide']);
394 unset($allow[
'delete']);
397 unset($allow[
'edit']);
398 unset($allow[
'move']);
399 unset($allow[
'hide']);
402 unset($allow[
'delete']);
405 unset($allow[
'new']);
430 trigger_error(
'FrontendBackendUserAuthentication->extGetLL() will be removed in TYPO3 v10.0.', E_USER_DEPRECATED);
431 if (!is_array(
$GLOBALS[
'LOCAL_LANG'])) {
433 if (!is_array(
$GLOBALS[
'LOCAL_LANG'])) {