[BUGFIX] MailUtility::parseAddresses() returns @localhost on empty string 39/20839/4
authorPhilipp Gampe <philipp.gampe@typo3.org>
Thu, 16 May 2013 17:01:17 +0000 (19:01 +0200)
committerJigal van Hemert <jigal@xs4all.nl>
Sun, 19 May 2013 08:08:53 +0000 (10:08 +0200)
commit3ecec35459bcb383b56aa1afa664a3839d32299c
tree2eb5e666add20538e1e5ddfddd5f2540c86e3ec8
parent7e33ae9f7645ba5388877e67dca71bc98ef34c18
[BUGFIX] MailUtility::parseAddresses() returns @localhost on empty string

parseAddresses should return an array of email addresses ready to be
feed into swiftmailer.
If an empty string is passed to the function, then it returns
"@localhost", which is not a valid email.
Swiftmailer will throw an exception "Address in mailbox given
[@localhost] does not comply with RFC 2822, 3.6.2."
This happens in ContentObjectRenderer->sendNotifyEmail() which is in
turn used by the frontend login forgotten passwort form.

Skip any addresses without a mailbox given.

Resolves: #48247
Releases: 6.2, 6.1
Change-Id: If8724416b3451417db7729dc81abdbd068dc8b10
Reviewed-on: https://review.typo3.org/20839
Tested-by: Philipp Gampe
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
Reviewed-by: Jigal van Hemert
Tested-by: Jigal van Hemert
typo3/sysext/core/Classes/Utility/MailUtility.php
typo3/sysext/core/Tests/Unit/Utility/MailUtilityTest.php