Project

General

Profile

Actions

Bug #93766

closed

BE user emailMeAtLogin throws TypeError

Added by Stefan Froemken almost 3 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Must have
Category:
Backend User Interface
Target version:
Start date:
2021-03-17
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
10
PHP Version:
7.3
Tags:
Complexity:
easy
Is Regression:
Sprint Focus:

Description

Hello,

I have activated emailMeAtLogin in my BE user settings and of cause I have an email address assigned. After log out and log in this TypeError was thrown:

Argument 1 passed to TYPO3\CMS\Core\FormProtection\FormProtectionFactory::getMessageClosure() must be an instance of TYPO3\CMS\Core\Localization\LanguageService, null given, called in /var/www/html/public/typo3/sysext/core/Classes/FormProtection/FormProtectionFactory.php on line 115

Tested on TYPO3 10.4.12 and 10.4.14

I have tried to debug that.

In Middleware\BackendUserAuthenticator we have these lines:

$GLOBALS['BE_USER']->backendCheckLogin($this->isLoggedInBackendUserRequired($pathToRoute));
$GLOBALS['LANG'] = LanguageService::createFromUserPreferences($GLOBALS['BE_USER']);

The upper line will check for first login and tries to send an email. The HTML email is Fluid-based and contains an image titled with "TYPO3 Logo". The ImageServices calls an Image-Task. The Task calls the DeferredBackendImageProcessor. From there the UriBuilder with method buildUriForRoute will be called, which will generate a form token as access to route is not public. The self::getMessageClosure expected $GLOBALS['LANG'] to be of type LanguageService.

But as you see $GLOBALS['LANG'] will be initialized after emailMeAtLogin.


Related issues 3 (0 open3 closed)

Related to TYPO3 Core - Task #92953: Drop usages of TYPO3_MODE and TYPO3_REQUESTTYPEClosed2020-11-30

Actions
Related to TYPO3 Core - Bug #93133: Not processing images when indexing in SolrClosed2020-12-21

Actions
Related to TYPO3 Core - Bug #93245: Images not processed in Scheduler task since version 10.4.11Closed2021-01-08

Actions
Actions #1

Updated by Stefan Froemken almost 3 years ago

  • Related to Task #92953: Drop usages of TYPO3_MODE and TYPO3_REQUESTTYPE added
Actions #2

Updated by Gerrit Code Review almost 3 years ago

  • Status changed from New to Under Review

Patch set 1 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68494

Actions #3

Updated by Stefan Froemken almost 3 years ago

  • Assignee set to Stefan Froemken
  • Complexity set to easy

Problem is already solved in v11. See related issue.

Actions #4

Updated by Gerrit Code Review almost 3 years ago

Patch set 2 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68494

Actions #5

Updated by Daniel Goerz almost 3 years ago

  • Related to Bug #93133: Not processing images when indexing in Solr added
Actions #6

Updated by Daniel Goerz almost 3 years ago

  • Related to Bug #93245: Images not processed in Scheduler task since version 10.4.11 added
Actions #7

Updated by Gerrit Code Review almost 3 years ago

Patch set 3 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68494

Actions #8

Updated by Gerrit Code Review almost 3 years ago

Patch set 1 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68518

Actions #9

Updated by Gerrit Code Review almost 3 years ago

Patch set 2 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68518

Actions #10

Updated by Helmut Hummel almost 3 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #11

Updated by Benni Mack almost 3 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF